Generate a tarball from the active workspace.
$> yarn pack [--install-if-needed] [-n,--dry-run] [--json] [-o,--out #0] [--filename #0]
Create an archive from the active workspace :
List the files that would be made part of the workspace's archive :
yarn pack --dry-run
Name and output the archive in a dedicated folder :
yarn pack --out /artifacts/%s-%v.tgz
This command will turn the active workspace into a compressed archive suitable
for publishing. The archive will by default be stored at the root of the
--install-if-needed flag is set Yarn will run a preliminary
install if the package contains build scripts.
-n,--dry-run flag is set the command will just print the file paths
without actually generating the package archive.
--json flag is set the output will follow a JSON-stream output also
known as NDJSON (https://github.com/ndjson/ndjson-spec).
-o,---out is set the archive will be created at the specified path. The
%v variables can be used within the path and will be respectively
replaced by the package name and version.