Skip to content

Getting Started

This guide gets a repository to the point where LocalCI runs checks after each commit.

Set up a repository

Install LocalCI

LocalCI runs Mise tasks, so make sure Mise is installed before you configure a repository.

With brew

brew tap irskep/tap
brew install localci

With mise

If you want everyone working in a repository to use the same LocalCI toolchain, install LocalCI through mise's GitHub backend:

mise.toml
[tools]
"github:irskep/localci" = "0.2.10"
mise install

Start the daemon

localci start

Read docs in the terminal

localci docs

Use localci docs --plain when you want plain text for scripts, pagers, or agents.

Install the hook

From the repository root:

localci install-hooks

After each commit, the hook enqueues checks and prints commands for status and waiting.

Define tasks

LocalCI executes all tasks with localci: in their name, and always executes localci:setup first.

mise.toml
[tasks."localci:setup"]
description = "Install dependencies for LocalCI runs"
run = [
  # 'mise trust' is run automatically, so you can usually just install dependencies immediately
  "mise install",
]

[tasks."localci:test"]
description = "go test"
run = "go test ./..."

Commit the setup

Commit the LocalCI task definitions so the post-commit hook can enqueue checks for the new revision:

git add mise.toml
git commit -m "Configure LocalCI"

Run checks

Follow the latest run

The normal workflow is post-commit: the hook queues work after each commit, and you inspect the daemon's latest run.

Wait in the terminal:

localci wait

Show a bounded status summary without waiting:

localci status

Open the same run in a browser or terminal UI:

localci web
localci dash

After localci postcommit enqueues tasks, use the wait command it prints:

localci wait --repo <repo> --commit <commit>

To inspect an existing no-clone run:

localci wait --commit 'HEAD*'

Run an ad hoc daemon check

Use run when you explicitly want to queue a manual daemon-managed run outside the post-commit path.

localci run --task test --wait

To test uncommitted changes through the daemon queue, use --no-clone:

localci run --no-clone --task test --wait

No-clone runs are labeled with a trailing *. They intentionally see unstaged files and local edits.

Use invoke only when you want to run checks directly in the current terminal instead of through the daemon.

Inspect results

Check status

Show the latest run for the current repository:

localci status

Show one task:

localci status --task noisy-fail

Show a specific run:

localci status --commit 6bd8d389f3f550da3fccb11bac380d59268fe320

Non-interactive commands print bounded summaries. They do not dump full logs.

Find artifact paths

Print artifact paths for the latest run:

localci artifacts

Print the primary artifact for failed tasks:

localci artifacts --failed --primary

For shell scripts and agents, print only paths:

localci artifacts --task noisy-fail --primary --paths-only

Then read the file directly:

cat "$(localci artifacts --task noisy-fail --primary --paths-only)"

Browse history

Show recent runs:

localci history

Show recent results for a task across commits:

localci history --task noisy-fail

Show recent failed runs:

localci history --failed

Open UIs

Open the web UI

Open the latest run for the current repository:

localci web

Open a specific task:

localci web --task noisy-fail

Task artifact pages show full artifact paths and include copy/open actions.

Use the terminal UI

Open the all-repos dashboard:

localci dash

Open a specific task:

localci dash --task noisy-fail

The terminal UI supports the same run, task, retry, cancel, and artifact views as the web UI. On artifact views, use e to edit the selected artifact with $VISUAL or $EDITOR, o to open it with the platform opener, and f on macOS to reveal it in Finder through the daemon.

Manage queued work

Cancel work

Cancel the active task:

localci cancel

Cancel a specific task:

localci cancel --commit HEAD --task test