Skip to content

Preserve generated Swift flags in Example projects - #962

Merged
Kyle-Ye merged 1 commit into
mainfrom
bugfix/example
Aug 1, 2026
Merged

Preserve generated Swift flags in Example projects#962
Kyle-Ye merged 1 commit into
mainfrom
bugfix/example

Conversation

@Kyle-Ye

@Kyle-Ye Kyle-Ye commented Aug 1, 2026

Copy link
Copy Markdown
Member

Summary

Remove the target-level OTHER_SWIFT_FLAGS overrides from both Example package manifests.

Why

The overrides replaced the Swift flags generated from the package target settings. This dropped the AvailabilityMacro feature flags when generating the Example project after the OpenSwiftUI ABI namespace flag was added.

Allowing Tuist to use the package-generated settings preserves both the availability feature flags and -module-abi-name OpenSwiftUI for OpenSwiftUICore.

Validation

The Example workspace regenerates successfully, and the resolved OpenSwiftUICore build settings contain both the availability macro flags and the OpenSwiftUI module ABI name.

@github-actions github-actions Bot added area: example Example apps, previews, sample projects, screenshots, or demo assets. area: tooling Developer tooling, package manifests, Tuist, scripts, formatting, or release tooling. type: bug Something is not working correctly. labels Aug 1, 2026
@Kyle-Ye
Kyle-Ye marked this pull request as ready for review August 1, 2026 12:31
@augmentcode

augmentcode Bot commented Aug 1, 2026

Copy link
Copy Markdown
🤖 Augment PR Summary

Summary: Removes OTHER_SWIFT_FLAGS overrides from the Example Tuist package manifests so SwiftPM-generated target flags are preserved.

Why: Avoids dropping the availability macro flags and keeps OpenSwiftUICore’s -module-abi-name OpenSwiftUI when regenerating the Example project.

🤖 Was this summary useful? React with 👍 or 👎

@augmentcode augmentcode Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed. No suggestions at this time.

Comment augment review to trigger a new review at any time.

@augmentcode augmentcode Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Risk Analyzer Agent🛡️

Risk Analysis 🛡️ · Low Risk

✅ Approved — Low-Risk Change

Details

Both edits only remove a target-level OTHER_SWIFT_FLAGS override that lives inside the #if TUIST block, so they affect only Tuist Example-project generation — not swift build, the shipped library, or its consumers.

The OpenSwiftUICore SPM target still sets -module-abi-name OpenSwiftUI directly via .unsafeFlags, so the ABI name is preserved; dropping the override lets Tuist use the package-generated flags that also restore the AvailabilityMacro features.

No executable code paths, tests, schemas, auth, or dependencies change, and the author validated that the workspace regenerates with both flag sets present.

@augmentcode augmentcode Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deep Code Review Agent🐛

Review completed with 0 suggestions.

Kyle-Ye commented Aug 1, 2026

Copy link
Copy Markdown
Member Author

/uitest ios

@Kyle-Ye
Kyle-Ye merged commit 989296b into main Aug 1, 2026
2 of 10 checks passed
@Kyle-Ye
Kyle-Ye deleted the bugfix/example branch August 1, 2026 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: example Example apps, previews, sample projects, screenshots, or demo assets. area: tooling Developer tooling, package manifests, Tuist, scripts, formatting, or release tooling. type: bug Something is not working correctly.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant