Package collection generator - not found

I am trying to play around with the newly introduced Package collections and generate my own collection in the process. The problem is, when I am running the help CLI command (as in the GitHub repository):

swift run package-collection-generate --help

I get error: root manifest not found despite I am using Swift 5.5 toolchain.

Am I doing anything wrong here? Is this package not added yet to the dev toolchain maybe?

Thanks for your help.

Works for me with the current tip of main:

❯ swift --version
Apple Swift version 5.4 (swiftlang-1205.0.26.9 clang-1205.0.19.55)
Target: arm64-apple-darwin20.5.0
~/P/G/swift-package-collection-generator on  main
❯ git rev-parse @
0cdcfa6c60959ed663476e3095762a5d247085ca
~/P/G/swift-package-collection-generator on  main
❯ swift run package-collection-generate --help
[3/3] Linking package-collection-generate

* Build Completed!
OVERVIEW: Generate a package collection from the given list of packages.

USAGE: package-collection-generate <input-path> <output-path> [--working-directory-path <working-directory-path>] [--revision <revision>] [--auth-token <auth-token> ...] [--verbose]

Also for 5.5:

❯ env DEVELOPER_DIR="/Applications/Xcode 13.0 Beta 1.app" swift run package-collection-generate --help
[725/725] Build complete!
OVERVIEW: Generate a package collection from the given list of packages.

USAGE: package-collection-generate <input-path> <output-path> [--working-directory-path <working-directory-path>] [--revision <revision>] [--auth-token <auth-token> ...] [--verbose]

What revision of the package are you on?

> swift --version
Apple Swift version 5.4 (swiftlang-1205.0.26.9 clang-1205.0.19.55)
Target: x86_64-apple-darwin20.4.0

> git rev-parse @
0cdcfa6c60959ed663476e3095762a5d247085ca

Looks like the same.

Anyway, it works for me as well now as I cloned the repo locally. I would have thought it ships with the swift 5.5 snapshot :sweat_smile:.

Thanks @finestructure

Oh, I see. No, the package collection generator is a stand-alone tool that's not (yet?) integrated with the toolchain AFAIK. You need to pull that down separately.

Terms of Service

Privacy Policy

Cookie Policy