Luca is a lightweight tool manager for macOS that helps developers install, manage, and activate specific versions of development tools in their projects. It creates project-specific tool environments without polluting your global PATH.
- Version-specific installations: Install specific versions of tools needed for your project
- Project isolation: Each project can have its own set of active tools
- Simple specification: Define required tools in a simple YAML file (Lucafile)
- Zero configuration: Just create a Lucafile and run
luca install - No PATH pollution: Tools are symlinked locally in your project directory
- Idempotent operations: Safe to run multiple times
Install the latest version with
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/LucaTools/LucaScripts/HEAD/install.sh)"Optionally define per-project .luca-version files containing the desired version before running the above command
echo "1.0.0" > .luca-versiongit clone https://github.com/LucaTools/Luca.git
cd Luca
swift build -c release
cp -f .build/release/luca /usr/local/bin/luca- Create a
Lucafilein your project directory:
---
tools:
- name: FirebaseCLI
version: 14.12.1
url: https://github.com/firebase/firebase-tools/releases/download/v14.12.1/firebase-tools-macos
- name: SwiftLint
binaryPath: SwiftLintBinary.artifactbundle/swiftlint-0.61.0-macos/bin/swiftlint
version: 0.61.0
url: https://github.com/realm/SwiftLint/releases/download/0.61.0/SwiftLintBinary.artifactbundle.zip
- name: Tuist
binaryPath: tuist
version: 4.80.0
url: https://github.com/tuist/tuist/releases/download/4.80.0/tuist.zip- Install the tools:
luca installYou can also install tools directly from GitHub releases by specifying the organization, repository, and version:
luca install TogglesPlatform/ToggleGen@1.0.0Specify the name of the release asset if the naming is not clear enough for Luca to work it out:
luca install krzysztofzablocki/sourcery@2.2.7 --asset sourcery-2.2.7.zipSymlinks will be created in the current directory at .luca/active.
- Use your tools:
tuist --help
swiftlint --helpUninstall a specific tool version:
luca uninstall SwiftLint
# Prompts to select a version to uninstallOr specify the version directly:
luca uninstall SwiftLint@0.61.0List all tools and versions installed:
luca installed
FirebaseCLI:
- 14.12.1
Sourcery:
- 2.2.5
SwiftLint:
- 0.53.0
- 0.62.0
tuist:
- 4.78.0List the tools linked in a project:
luca linked
FirebaseCLI:
version: 14.12.1
binary: firebasee
location: /Users/alberto/.luca/tools/FirebaseCLI/14.12.1/firebasee
Sourcery:
version: 2.2.5
binary: sourcery
location: /Users/alberto/.luca/tools/Sourcery/2.2.5/bin/sourcery
tuist:
version: 4.78.0
binary: tuist
location: /Users/alberto/.luca/tools/tuist/4.78.0/tuistRemove a symlink from the current project's .luca/active directory:
luca unlink swiftlintLuca performs the following steps:
- Reads the tool specifications from your Lucafile
- Downloads the specified zip files if they're not already installed
- Extracts the binaries to
~/.luca/tools/{tool-name}/{version}/ - Creates symlinks in
.luca/active/in your current directory - Tools can then be accessed via
.luca/active/{binary-name}
The Lucafile is a YAML file with the following structure:
---
tools:
- name: ToolName # Logical name for the tool
version: 1.2.3 # Version to install
url: https://example.com/tool-1.2.3.zip # Remote URL to an archive containing the tool or an executable file.
binaryPath: path/to/binary # Path to the binary within the archive file, if the release comes as an archive (optional)
desiredBinaryName: toolname # Name of the binary stored locally. Requires `url` to point to an executable file, ignored otherwise. (optional)
checksum: e0a6540d01434f436335a9... # The checksum hash of asset associated with the tool (optional)
algorithm: (md5|sha1|sha256|sha512) # The algorithm used to generate the checksum (optional)- macOS 13.0 or later
- Swift 5.7 or later (for building from source)
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
You can also contribute by buying me a coffee and letting me know on the socials X / Bluesky 😉
This project is licensed under the Apache 2.0 License - see the LICENSE file for details.
