Skip makePathRelative for folder-type sources since they use sourceTree
.sourceRoot and need the full project-relative path preserved. The call
was inadvertently added for all source types in #1596 but only synced
folders (.syncedFolder) need it.
Fixes#1603
* Add .context to .gitignore
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Validate empty source paths to prevent project root inclusion (#1595)
Empty/null source entries (e.g. bare `-` in YAML) resolve to the project
root, causing extreme memory usage. Add validation to reject them with a
clear error message.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* Added ProjectFormat enum with specific for each version fields
* Added ability to specify project format version via `projectFormat` option
---------
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
* Add explicitFolders support to syncedFolder
Adds an `explicitFolders` property to `TargetSource` that is expanded from Glob patterns and passed through to `PBXFileSystemSynchronizedRootGroup`.
* Fix syncedFolder sources ignoring createIntermediateGroups
When createIntermediateGroups was enabled and a syncedFolder source had a
multi-component path (e.g. SyncedParent/SyncedChild), two things went wrong:
1. The synced folder was unconditionally added to rootGroups, causing it
to appear both at the project root and inside the correct intermediate
parent group.
2. The synced folder kept its full project-relative path instead of being
made relative to its parent group, so Xcode concatenated them into a
wrong path (e.g. SyncedParent/SyncedParent/SyncedChild).
* Enhance PBXFileElement to recognize synced folders as groups that can be sorted
* Fix membership exceptions for nested synced folder with intermediate groups
* Update Changelog
Gate the supportedDestinations YAML preset block inside the applyTarget check so that settingPresets: none (and project) suppresses Catalyst-related settings (SUPPORTS_MACCATALYST, SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD, SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD) that were previously always injected.
Fixes#1598
* Handle membership exceptions for synchronized root groups
Adds logic to detect and register membership exceptions for PBXFileSystemSynchronizedRootGroup objects, specifically excluding Info.plist files from group membership when necessary. Also ensures resources build phase is added if synchronized root groups are present.
* Refactor synced folder membership exceptions with glob support
Extract configureMembershipExceptions into its own method, use Set for
dedup, resolve excludes via glob expansion, and add a no-op test case.
Incorporates glob support and tests from macguru@baf1108.
* Update UUID
* Comment out excludes in project.yml
Comment out excludes for ExcludedFile.swift due to CI issue.
* Clean up project.pbxproj by removing exception set
Removed PBXFileSystemSynchronizedBuildFileExceptionSet section and its references.
* Remove comment
* Update SourceGeneratorTests.swift
* Update project.pbxproj
* Retrigger CI
* Add info.plist exclusion
- Add explicit -destination flags to build.sh — newer Xcode versions no
longer auto-select a build destination, causing "Found no destinations
for the scheme" errors
- Update CI matrix to Xcode 16.4 and 26.2 — Xcode 16.0-16.3 simulator
runtimes are no longer installed on the macos-15 runner image
- Add PRODUCT_BUNDLE_IDENTIFIER to ExternalTarget fixture — Xcode 26.x
requires a bundle identifier for embedded frameworks
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* Custom error handler
* Check for error reason and expected type
* Improvements
* Update CHANGELOG.md
* Update master (#1)
* Update CI equipments and drop Xcode 15 support (#1548)
* Add validation to ensure that settings.configs values are dictionaries, in order to prevent misuse (#1547)
* Add validation to ensure settings.configs values are dictionaries to prevent misuse
* Add tests for invalid settings.configs value formats
* Replaced with filter and split into a function
* Rename invalidConfigsFormat to invalidConfigsMappingFormat
* Add comments to explain invalid fixture
* Rename test fixture
* Update CHANGELOG.md
* Correct grammer
* Use KeyPath instead of closure
* Rename validateMappingStyleInConfig to extractValidConfigs
* Add a document comment for extractValidConfigs(from:)
* Use old testing api and remove EquatableErrorBox
* Rename test case to use "mapping" instead of "dictionary"
* Add ValidSettingsExtractor to encapsulate the logic for converting a dictionary to Settings
* Add settings validation for both Target and AggregateTarget
* Add tests for invalid settings.configs in Target and AggregateTarget
* Add document comments for ValidSettingsExtractor
* Rename ValidSettingsExtractor to BuildSettingsExtractor
* Add settings validation for settingGroups
* Add tests for settingGroups
* Rename extract to parse
* Refactor
* Update Tests/ProjectSpecTests/InvalidConfigsFormatTests.swift
---------
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
* Synced folders (#1541)
* update xcodeproj to 8.27.7
* add syncedFolder source type
* drop xcode 15 support
* Rely on fileReference instead of adding new synchronizedRootGroup (#1557)
* fix: don't include untracked children in cache
---------
Co-authored-by: Kirill Yakimovich <kirill.yakimovich@gmail.com>
* Use USER env var instead of LOGNAME (#1559)
During user switch with su/sudo in system LOGNAME may not be initialised, but USER env var is always exist.
* Address Sanitizer options in run/test schemes (#1550)
* Expose address sanitizer flags in run and test BuildActions in Schemes
* Update testJSONEncodable to test the new fields
* Also test the asan setting values for run scheme
* Update changelog
---------
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
* Update to 2.44.0
# Conflicts:
# CHANGELOG.md
---------
Co-authored-by: Kohki Miki <giginet.net@gmail.com>
Co-authored-by: Ryu <87907656+Ryu0118@users.noreply.github.com>
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
Co-authored-by: Kirill Yakimovich <kirill.yakimovich@gmail.com>
Co-authored-by: Kanstantsin Shautsou <kanstantsin.sha@gmail.com>
Co-authored-by: Himanshu Kumar <7786778+hi-kumar@users.noreply.github.com>
* Revert
* Refactoring started
* func json(atKeyPath keyPath: String) -> String?
* All cases
---------
Co-authored-by: Kohki Miki <giginet.net@gmail.com>
Co-authored-by: Ryu <87907656+Ryu0118@users.noreply.github.com>
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
Co-authored-by: Kirill Yakimovich <kirill.yakimovich@gmail.com>
Co-authored-by: Kanstantsin Shautsou <kanstantsin.sha@gmail.com>
Co-authored-by: Himanshu Kumar <7786778+hi-kumar@users.noreply.github.com>
* Added `customWorkingDirectory` and `useCustomWorkingDirectory` properties to `Scheme.Run`
* Use new `customWorkingDirectory` and `useCustomWorkingDirectory` when generating `XCScheme.LaunchAction`
* Updated ProjectSpec.md to document new `customWorkingDirectory` and `useCustomWorkingDirectory` properties
* Fix for not setting customWorkingDirectory in the toJSONValue function
* Added test to make sure usCustomWorkingDirectory value is true when the customWorkingDirectory is set to non nil
* Change to infer the value of SchemaGenerator.LaunchAction.useCustomWorkingDirectory based on the value of Schema.Run.customWorkingDirectory
* Removed useCustomWorkingDirectory from the project spec now that it is no longer user defined.
* Expose address sanitizer flags in run and test BuildActions in Schemes
* Update testJSONEncodable to test the new fields
* Also test the asan setting values for run scheme
* Update changelog
---------
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
* update xcodeproj to 8.27.7
* add syncedFolder source type
* drop xcode 15 support
* Rely on fileReference instead of adding new synchronizedRootGroup (#1557)
* fix: don't include untracked children in cache
---------
Co-authored-by: Kirill Yakimovich <kirill.yakimovich@gmail.com>
* Add validation to ensure settings.configs values are dictionaries to prevent misuse
* Add tests for invalid settings.configs value formats
* Replaced with filter and split into a function
* Rename invalidConfigsFormat to invalidConfigsMappingFormat
* Add comments to explain invalid fixture
* Rename test fixture
* Update CHANGELOG.md
* Correct grammer
* Use KeyPath instead of closure
* Rename validateMappingStyleInConfig to extractValidConfigs
* Add a document comment for extractValidConfigs(from:)
* Use old testing api and remove EquatableErrorBox
* Rename test case to use "mapping" instead of "dictionary"
* Add ValidSettingsExtractor to encapsulate the logic for converting a dictionary to Settings
* Add settings validation for both Target and AggregateTarget
* Add tests for invalid settings.configs in Target and AggregateTarget
* Add document comments for ValidSettingsExtractor
* Rename ValidSettingsExtractor to BuildSettingsExtractor
* Add settings validation for settingGroups
* Add tests for settingGroups
* Rename extract to parse
* Refactor
* Update Tests/ProjectSpecTests/InvalidConfigsFormatTests.swift
---------
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
* Support preferred screen capture format in scheme test action (resolves#1443)
* preferredScreenCaptureFormat decoding test
---------
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
* Respect relativePaths in local package paths
Before this a local package defined in an included file would not
respect relativePaths: true.
This fixes#1497.
* Test local package with relative path
* add relative paths support to localPackages syntax
---------
Co-authored-by: Yonas Kolb <yonaskolb@users.noreply.github.com>
The preGenCommand may generate files, change paths, etc. If we run this after checking the cache, it never gets the chance to run if the cache hasn't changed. Running it before checking the cache lets us make these changes and _then_ we can check the cache to see if we need to regenerate or not.
Co-authored-by: Dale Myers <dalemyers@microsoft.com>