Repository navigation
Conversation
The command's own findings join the parser's, each with its fix: - RejectedOption: a flag the command's policy refuses (mode switching, test-only); the message says whether xcodebuild refuses or ignores it there; - ActionInOptions: a build action (clean, build) in the options; the command sets its own; - PreferStepInput: -allowProvisioningUpdates on its own; xcodebuild needs the API key flags the Step adds when automatic code signing is enabled, so it points at that input; - what the merge resolved: RepeatedOption (xcodebuild will refuse it), and the informational RedundantOption and Override, which Fail lets through; - a "-flag=value" next to the Step's "-flag value", which xcodebuild ignores; for a switch the fix is to remove it. ExampleArchive shows the call site steps-xcode-archive ends up with. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This was referenced Oct 9, 2026
lpusok
added this pull request to stack #365
October 9, 2026 12:56
lpusok
marked this pull request as ready for review
October 9, 2026 12:57
There was a problem hiding this comment.
🟡 Changes recommended
Validation can reject valid manual authentication and accept malformed switch overrides.
2 open findings
What changed in this PR
Adds command-aware diagnostics for user-supplied xcodebuild_options.
Changes:
- Reports policy violations, collisions, redundant options, and malformed flag forms.
- Adds validation tests and an archive usage example.
- Integrates merge results into command diagnostics.
| File | Description |
|---|---|
xcodecommand/command.go |
Passes merge context into diagnostics. |
xcodecommand/diagnostic.go |
Adds command and collision diagnostics. |
xcodecommand/diagnostic_test.go |
Tests validation kinds and messages. |
xcodecommand/example_test.go |
Demonstrates archive option merging. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+144
to
+145
| hint, ok := stepInputFlags[o.Key()] | ||
| if !ok || slices.ContainsFunc(derived, func(d Option) bool { return d.Key() == o.Key() }) { |
Comment on lines
+186
to
+187
| case overridden: | ||
| diagnostics = append(diagnostics, Diagnostic{Kind: Override, Message: fmt.Sprintf("%q replaces the Step's default %q.", c.user.join(), c.derived)}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

The command's own findings join the parser's, each with its fix:
message says whether xcodebuild refuses or ignores it there;
the Step adds when automatic code signing is enabled, so it points at that input;
RedundantOption and Override, which Fail lets through;
the fix is to remove it.
ExampleArchive shows the call site steps-xcode-archive ends up with.
🤖 Generated with Claude Code