{"id":17160561,"url":"https://github.com/josephduffy/update-xcode-version-action","last_synced_at":"2025-07-14T15:37:54.218Z","repository":{"id":38426822,"uuid":"269688110","full_name":"JosephDuffy/update-xcode-version-action","owner":"JosephDuffy","description":"GitHub Action to automate Xcode updates","archived":false,"fork":false,"pushed_at":"2023-01-07T00:20:31.000Z","size":2342,"stargazers_count":7,"open_issues_count":4,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-06T20:07:45.876Z","etag":null,"topics":["github-actions","swift","xcode"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JosephDuffy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-06-05T15:41:13.000Z","updated_at":"2023-02-07T17:39:12.000Z","dependencies_parsed_at":"2023-01-11T17:21:32.268Z","dependency_job_id":null,"html_url":"https://github.com/JosephDuffy/update-xcode-version-action","commit_stats":{"total_commits":310,"total_committers":4,"mean_commits":77.5,"dds":"0.39032258064516134","last_synced_commit":"46b46c9d2640819b11a8ae9d0907057bf69b4757"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/JosephDuffy/update-xcode-version-action","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JosephDuffy%2Fupdate-xcode-version-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JosephDuffy%2Fupdate-xcode-version-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JosephDuffy%2Fupdate-xcode-version-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JosephDuffy%2Fupdate-xcode-version-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JosephDuffy","download_url":"https://codeload.github.com/JosephDuffy/update-xcode-version-action/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JosephDuffy%2Fupdate-xcode-version-action/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265313313,"owners_count":23745188,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["github-actions","swift","xcode"],"created_at":"2024-10-14T22:25:15.318Z","updated_at":"2025-07-14T15:37:54.199Z","avatar_url":"https://github.com/JosephDuffy.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# update-xcode-version-action\n\n![Tests](https://github.com/JosephDuffy/update-xcode-version-action/workflows/Tests/badge.svg)\n[![codecov](https://codecov.io/gh/JosephDuffy/update-xcode-version-action/branch/master/graph/badge.svg)](https://codecov.io/gh/JosephDuffy/update-xcode-version-action)\n\n`update-xcode-version-action` is a GitHub Action that utilises [`xcutils`](https://github.com/JosephDuffy/xcutils) to automate the creation of pull requests when a new Xcode version is available (on GitHub Actions).\n\nIt can be configured to update GitHub Actions workflow files and create a pull request with the changes.\n\nThanks to `xcutils` [versions can be specified as `latest`, `beta`, `last-minor`, etc.](https://github.com/JosephDuffy/xcutils#version-specifiers), allowing for a single configuration to continue working without the need for extra tweaking. **You can think of your versions specification as a lock file for Xcode versions**.\n\n## Configuration\n\nXcode versions are configured using a yaml file. By default the action will look for a file at `.github/xcode-versions.yml`, but you can configure it to look elsewhere.\n\nFor example to have a release workflow use the latest Xcode and tests to use the next available beta and the last minor version you can create a yaml file such as:\n\n```yaml\nworkflows:\n  workflows/test.yml:\n    jobs:\n      run_tests:\n        strategy:\n          matrix:\n            xcode:\n              - last-minor\n              - latest\n              - beta\n\n  workflows/release.yml:\n    jobs:\n      release:\n        strategy:\n          matrix:\n            xcode:\n              - latest\n```\n\nThis would update a workflow file with the following structure:\n\n```yaml\nname: Tests\n\non: [push]\n\njobs:\n  run_tests:\n    name: Run Tests\n    runs-on: macos-latest\n    strategy:\n      fail-fast: false\n      matrix:\n        xcode: [\"11.1\", \"11.2.1\", \"11.3-beta\"]\n\n    steps:\n      - uses: actions/checkout@v2\n\n      - name: Select Xcode ${{ matrix.xcode }}\n        run: sudo xcode-select --switch /Applications/Xcode_${{ matrix.xcode }}.app\n\n      run: xcodebuild ... # Run your tests\n```\n\nRunning a check for updates can be done automatically or manually by adding a new workflow to the project that runs the `update-xcode-version-action` action, e.g.:\n\n```yaml\nname: \"Check for Xcode Updates\"\n\non:\n  # Allow to be run manually\n  workflow_dispatch:\n\n  # Run at 8am UTC daily\n  schedule:\n    - cron: \"0 8 * * *\"\n\njobs:\n  update-xcode-versions:\n    name: Check for Xcode Updates\n    runs-on: macOS-latest\n    steps:\n      - uses: actions/checkout@v2\n        with:\n          token: ${{ secrets.UPDATE_XCODE_VERSIONS_GITHUB_TOKEN }} # A token that can update workflows, required to push changes to workflow files\n\n      - name: Update Xcode Versions\n        uses: josephduffy/update-xcode-version-action@master\n        with:\n          github-token: ${{ secrets.GITHUB_TOKEN }} # Required to create pull requests, can be the default token provided by GitHub Actions\n          xcode-versions-file: .github/xcode-versions.yml # Default, not required, but can be changed\n```\n\nWhen `update-xcode-version-action` discovers a change in the resolved versions it will create a pull request with the changes.\n\n## Badge Generation\n\n`update-xcode-version-action` can be configured to create a badge that displays the supported Xcode versions, which fits in well for use in READMEs.\n\n```yaml\n# ...\n- name: Update Xcode Versions\n  uses: josephduffy/update-xcode-version-action@master\n  with:\n    xcode-version-badge-path: ./.github/xcode-versions-badge.svg # Provide a path to output the badge to\n    xcode-version-badge-versions: \"last-major, latest, beta\" # A comma separated list of versions to display in the badge. Defaults to \"latest\".\n    # ...\n```\n\nThis would produce: [![Example badge](https://raw.githubusercontent.com/JosephDuffy/update-xcode-version-action/update-xcode-version-action/update-xcode-versions/.github/xcode-versions-badge.svg)](https://github.com/JosephDuffy/update-xcode-version-action/blob/update-xcode-version-action/update-xcode-versions/.github/xcode-versions-badge.svg)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjosephduffy%2Fupdate-xcode-version-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjosephduffy%2Fupdate-xcode-version-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjosephduffy%2Fupdate-xcode-version-action/lists"}