What exactly is the real name of this package?

in light of the recent discussion at [Second review] SE-0386: `package` access modifier i wonder if the proliferation of swift- prefixes is because of a particular handicap of SPM: right now we cannot have more than one package per git repository.

this has caused us to treat repositories and packages as one and the same, and so SPM uses the repository name as the package identity. and repositories must have swift- prefixes (since they coexist in the same namespace as projects written in other languages), which implies that package identities must too have swift- prefixes.

i hope if SPM gets support for multi-package repositories, that we can dispense with the swift- prefixes once and for all.


as an aside: i don’t think there is any value in a package name: field in the manifest that deviates from the identity SPM uses everywhere else - it is just confusing. perhaps it should be renamed to displayName:, or removed entirely.

7 Likes