Skip to content

Add options.createLocalPackageGroups to suppress local package folder references#1631

Open
vahan3x wants to merge 1 commit into
yonaskolb:masterfrom
vahan3x:feature/suppress-local-package-group
Open

Add options.createLocalPackageGroups to suppress local package folder references#1631
vahan3x wants to merge 1 commit into
yonaskolb:masterfrom
vahan3x:feature/suppress-local-package-group

Conversation

@vahan3x

@vahan3x vahan3x commented Jul 17, 2026

Copy link
Copy Markdown

Local Swift packages get a dual representation in generated projects: the XCLocalSwiftPackageReference shown under Package Dependencies (desirable) and a redundant folder PBXFileReference in a group, Packages by default (often not). options.localPackagesGroup: "" only relocates that folder to the project root; it cannot remove it (see #1209).

This adds options.createLocalPackageGroups (default true). When set to false, XcodeGen still emits the package reference so Package Dependencies is populated, but skips the folder reference/group for all local packages — matching what Xcode produces via "Add Package Dependencies… → Add Local".

Default true = current output preserved byte-for-byte (no fixture changes needed)
New tests: spec parsing (default + explicit false + encode/decode round-trip) and generator behavior (no Packages group / folder refs, package references intact)
Docs (ProjectSpec.md) and CHANGELOG.md updated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant