Skip to content

Set up your GitHub Actions workflow with a specific version of Xcode

License

Notifications You must be signed in to change notification settings

maxim-lobanov/setup-xcode

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

cb46b9b · Apr 23, 2021

History

22 Commits
Oct 15, 2020
Apr 3, 2021
Apr 23, 2021
Apr 3, 2021
May 1, 2020
May 1, 2020
May 1, 2020
Oct 10, 2020
May 1, 2020
May 1, 2020
Apr 2, 2021
Oct 10, 2020
May 1, 2020
May 1, 2020

Repository files navigation

setup-xcode

This action is intended to switch between pre-installed versions of Xcode for macOS images in GitHub Actions.

The list of all available versions can be found in virtual-environments repository.

Available parameters

Argument Description Format
xcode-version Specify the Xcode version to use - latest or
- latest-stable or
- SemVer string

Notes:

  • latest-stable points to the latest stable version of Xcode
  • latest includes beta releases that GitHub actions has installed
  • SemVer examples: 10, 11.4, 12.0, 11.7.0, ^11.7.0 (find more examples in SemVer cheatsheet)
  • If sets a specific version, wraps it to single quotes in YAML like '12.0' to pass it as string because GitHub trimmes trailing .0 from numbers

Usage

Set the latest stable Xcode version:

jobs:
  build:
    runs-on: macos-latest
    steps:
    - uses: maxim-lobanov/setup-xcode@v1
      with:
        xcode-version: latest-stable

Set the latest Xcode version including beta releases:

jobs:
  build:
    runs-on: macos-latest
    steps:
    - uses: maxim-lobanov/setup-xcode@v1
      with:
        xcode-version: latest

Set the specific version of Xcode:

jobs:
  build:
    runs-on: macos-latest
    steps:
    - uses: maxim-lobanov/setup-xcode@v1
      with:
        xcode-version: '12.0'

License

The scripts and documentation in this project are released under the MIT License