chocolateyFiles top-level property
The set of files to include directly in the Chocolatey package.
This should be at least enough files to compile the package's executables.
It defaults to all files in lib/
and bin/
, as well as pubspec.lock
.
The pubspec.yaml
file is always included regardless of the contents of
this field.
Implementation
final chocolateyFiles = InternalConfigVariable.fn<List<String>>(() => [
...['lib', 'bin']
.where((dir) => Directory(dir).existsSync())
.expand((dir) => Directory(dir).listSync(recursive: true))
.whereType<File>()
.map((entry) => entry.path),
'pubspec.lock'
]);