Getting started

Follow these steps to install run and try your first Runfile.

Install

macOS/Linux (Homebrew)

brew tap nihilok/tap
brew install runtool

Windows (Scoop)

scoop bucket add nihilok https://github.com/nihilok/scoop-bucket
scoop install runtool

All platforms (Cargo)

cargo install run   # or: cargo install runtool

Create your first Runfile

  1. Create a file named Runfile in your project root.
# @desc Deploy to an environment
# @arg env Target environment (staging|prod)
# @arg version Version to deploy (defaults to "latest")
deploy(env: str, version = "latest") {
    echo "Deploying $version to $env..."
    ./scripts/deploy.sh $env $version
}
  1. Run it from your terminal:
run deploy staging
run deploy prod v2.1.0
  1. List available functions to check discovery:
run --list
  1. Install shell completions (auto-detects your shell):
run --install-completion

Working directory

run searches upward from the current working directory for a Runfile. To point at another project explicitly, use --working-dir /path/to/project.

Next steps