Skip to content

Conversation

@devin-ai-integration
Copy link
Contributor

@devin-ai-integration devin-ai-integration bot commented Oct 19, 2025

Description

Linear ticket: N/A
Requested by: [email protected] (@jon-fern)
Session: https://app.devin.ai/sessions/efa19f877f014f9ea0a758cada9e7d0e

Added CI workflow generation for Swift SDK generator to match the behavior of Python, TypeScript, Go, Java, and other language generators. When generating SDKs with output mode set to "github", the Swift generator now creates a .github/workflows/ci.yml file with basic compile and test jobs.

Changes Made

  • Modified generators/swift/sdk/src/SdkGeneratorCli.ts:
    • Added conditional check in generate() method to call workflow generation when output mode is 'github'
    • Implemented generateGithubWorkflow() method that creates a CI workflow file
    • Workflow includes two jobs: compile (runs swift build) and test (runs swift test)
    • Uses Swift 6.0 with swift-actions/setup-swift@v2 action
  • Regenerated all 93 Swift SDK test fixtures to include the new CI workflow files
  • Updated seed test fixtures (all Swift SDK fixtures now include .github/workflows/ci.yml)

Testing

  • Ran pnpm seed test --generator swift-sdk successfully
    • 45/94 fixtures passed (49 failures were pre-existing expected failures)
    • All fixtures now include the generated CI workflow file
    • No new test failures introduced by this change
  • Verified workflow file structure matches pattern used by other language generators (Python, TypeScript, Go, Java)
  • Confirmed output mode conditional works correctly (only generates workflow in "github" mode)

Review Checklist

Important items to review:

  1. Swift version (6.0): Verify this is the appropriate version for production use cases. Based on seed.yml configuration, but should confirm this matches user expectations.

  2. Workflow structure: The workflow uses separate jobs for compile and test, matching other languages. Confirm this is the desired pattern vs. a single job with multiple steps.

  3. Build commands: Uses simple swift build and swift test commands. Verify no additional configuration, dependencies, or build flags are needed for Swift projects.

  4. Output mode check: Validates that context.config.output.mode.type === "github" is the correct conditional (follows pattern from Python/TypeScript generators).

  5. Fixture coverage: All 93 Swift SDK fixtures were regenerated. The large number of file changes is expected but worth scanning for any anomalies.

- Add CI workflow generation for Swift SDK generator
- Generate .github/workflows/ci.yml when output mode is 'github'
- Workflow includes compile and test jobs using Swift 6.0
- Matches pattern used by other language generators (Python, TypeScript, Go, etc.)

Co-Authored-By: [email protected] <[email protected]>
@devin-ai-integration
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant