# Install xcodes with Homebrew, MacPorts, Nix

Command-line tool to install and switch between multiple versions of Xcode. Version 2.0.2 via Homebrew; verified 2026-06-28.

## Install

```sh
sudo av install brew:xcodes
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install xcodes
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install xcodes
```

  Evidence: MacPorts ports tree: devel/xcodes/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#xcodes
```

  Evidence: nixpkgs package indexes: pkgs/by-name/xc/xcodes/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:xcodes
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/xcodes>
- **Version:** 2.0.2
- **Source summary:** Command-line tool to install and switch between multiple versions of Xcode
- **Homepage:** <https://github.com/XcodesOrg/xcodes>
- **Repository:** <https://github.com/XcodesOrg/xcodes>
- **Upstream docs:** <https://github.com/XcodesOrg/xcodes#readme>
- **License:** MIT
- **Source archive:** <https://github.com/XcodesOrg/xcodes/archive/refs/tags/2.0.2.tar.gz>
- **Last updated:** 2026-06-28T20:59:36+01:00
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- xcodes (cli)
- xcodes (alias)

## Uses from macOS

- swift

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_sequoia, arm64_tahoe

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 2.0.2
- Package-manager updated: 2026-06-28
- Local data: ok
- Upstream repository: https://github.com/XcodesOrg/xcodes
- Upstream latest detected: 2.0.2 (current)
## Project history and usage

xcodes is a Swift command-line tool for installing, listing, selecting, and removing multiple versions of Xcode. It fills the same role for Apple's IDE that language version managers fill for Ruby, Node, or Python projects.

### Project history

The repository was created on 2019-02-22 and shipped its initial 0.1.0 release on 2019-03-11 as an MVP for Apple developers who needed side-by-side Xcode installs. The README documents commands for installing specific releases and prereleases, listing available versions, selecting an active Xcode, managing runtimes, and uninstalling versions.

The project began under Robots and Pencils and moved into the XcodesOrg organization on 2023-04-21. The maintainer note describes the move as a response to growth beyond a small utility used by Apple developers around the world, while keeping Matt Kiazyk as owner and maintainer.

By 2024 and 2026, xcodes had adapted to changes in Apple's tooling and distribution model: releases added support for iOS 18+ runtime downloads and SRP Apple login changes, then 2.0.x refactored the CLI onto shared XcodesKit and XcodesLoginKit packages, added architecture-aware filtering, and raised the implementation baseline to Swift 6 and macOS 13.

### Adoption history

xcodes is widely adopted because Xcode versions are large, slow to install manually, and often need to be pinned per project or CI lane. The repository has thousands of GitHub stars and a long release line, and its companion Xcodes.app gives the same version-management idea a graphical macOS interface.

The .xcode-version proposal ties xcodes to a broader convention already used by xcode-install and fastlane. That file lets a repository declare the Xcode version it expects, making xcodes useful in onboarding scripts and CI environments where reproducible Apple build tooling matters.

### How it is used

Common workflows include running xcodes list to discover versions, xcodes install to download and install an exact Xcode version, xcodes select to switch the active toolchain through xcode-select, and xcodes runtimes to install platform runtimes. When authentication is required for Apple downloads, xcodes stores Apple ID credentials in the macOS Keychain after prompting or reading environment variables.

Teams often add a .xcode-version file next to an Xcode project or workspace so automation can choose the expected Xcode. The README recommends committing that file for teams and CI, especially when a project depends on a specific stable Xcode release.

### Why package nerds care

xcodes is significant in package-manager culture because it brings version-manager ergonomics to a toolchain Apple distributes as a huge GUI application. It makes Xcode itself scriptable: a package can select, install, and document the IDE/runtime version needed for deterministic builds.

### Timeline

- 2019-02-22: Repository created on GitHub.
- 2019-03-11: 0.1.0 initial MVP release.
- 2023-04-21: Xcodes projects moved from Robots and Pencils into XcodesOrg.
- 2023-06-23: 1.4.1 release highlighted runtime download and install support.
- 2024-10-30: 1.6.0 added Apple SRP login support and iOS 18+ runtime download support.
- 2026-06-08: 2.0.1 refactored the CLI around shared XcodesKit/XcodesLoginKit and architecture-aware downloads.
- 2026-06-17: 2.0.2 fixed a 2FA authentication regression.

### Related projects

- Xcodes.app is the native macOS GUI companion for the same workflow.
- fastlane and the legacy xcode-install gem are related because they also use or recognize .xcode-version-style Xcode pinning.

### Sources

- <https://github.com/XcodesOrg/XcodesApp>
- <https://github.com/XcodesOrg/xcodes>
- <https://github.com/XcodesOrg/xcodes/blob/main/XCODE_VERSION.md>
- <https://github.com/XcodesOrg/xcodes/blob/main/nextstep.md>
- <https://github.com/XcodesOrg/xcodes/releases>


## Security Notes

narrow executable package without higher-risk signals.

- **Geiger risk:** green / low
- narrow executable package without higher-risk signals


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: ./.xcode-version

## Credential files

- macOS: macOS Keychain
## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** xcodes
- **Version Scheme:** 0
- **Revision:** 0
- **Requirements:** macos, xcode
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

## Other Package-Manager Records

- Nix - xcodes: normalized package name match | nixpkgs package indexes: pkgs/by-name/xc/xcodes/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- MacPorts - xcodes: normalized package name match | MacPorts ports tree: devel/xcodes/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## Related links

- [Source-control packages](https://www.automicvault.com/pkg/source-control-tools/) - Belongs to a source-control command family.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [xcenv](https://www.automicvault.com/pkg/brew/xcenv/) - Shares av.db curated category or tags: apple-development, cli, developer-tools, version-manager, xcode.
- [juliaup](https://www.automicvault.com/pkg/brew/juliaup/) - Shares av.db curated category or tags: cli, developer-tools, installer, version-manager.
- [bob](https://www.automicvault.com/pkg/brew/bob/) - Shares av.db curated category or tags: cli, developer-tools, version-manager.
- [frum](https://www.automicvault.com/pkg/brew/frum/) - Shares av.db curated category or tags: cli, developer-tools, version-manager.
- [luaver](https://www.automicvault.com/pkg/brew/luaver/) - Shares av.db curated category or tags: cli, developer-tools, version-manager.
- [nave](https://www.automicvault.com/pkg/brew/nave/) - Shares av.db curated category or tags: cli, developer-tools, version-manager.
- [phpbrew](https://www.automicvault.com/pkg/brew/phpbrew/) - Shares av.db curated category or tags: cli, developer-tools, version-manager.
- [ry](https://www.automicvault.com/pkg/brew/ry/) - Shares av.db curated category or tags: cli, developer-tools, version-manager.
- [scalaenv](https://www.automicvault.com/pkg/brew/scalaenv/) - Local package facts share a topical domain. Shared terms: cli, command-line, developer, developer-tools, install.

## Combined YAML source

View the package source record on GitHub. [combined/xcodes.yml](https://github.com/automic-vault/db/blob/main/combined/xcodes.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
