Bare just runs the first recipe, not yours

Bare just runs the first recipe in the file, not the one you meant.

You save a Justfile and type just, expecting the dev server. The first line in the file is lint, so that is what runs. Bare just runs the first recipe, not the one you meant. When a diagram needs a shared page, start a room.

Stop when a justfile sits at the repo root, bare just prints the first recipe’s output, and the recipe you actually want is marked [default] or moved to the top. Search query: just default recipe first in justfile. Manual: just.systems/man/en/ (The Default Recipe). Upstream: github.com/casey/just.

just --versionWrite an echoBare justMark [default]
justno args = first
[default]explicit default
--listlists, does not run

File order is the contract

The manual: invoking just with no recipe name runs the recipe with the [default] attribute, or the first recipe in the justfile if none has it. In the snippet below, bare just always echoes linting; dev never starts by itself.

# justfile — first named recipe is what bare just runs
lint:
    echo linting

dev:
    echo starting server

Passing the check is not seeing names from just --list. That flag lists recipes alphabetically; add --unsorted for file order. A list is not a run.

  1. 1
    Confirm the binary

    just --version must print a version. Install notes: install just vs make. On Windows you need sh on PATH, or set shell to PowerShell / cmd as the README shows.

  2. 2
    Write one recipe that prints

    Put a justfile at the project root. Recipe bodies must be indented (spaces are fine; tabs are not required like Make). First recipe: hello: then echo hello-from-just. Commands echo to stderr before they run; prefix @ to hide that.

  3. 3
    Run it with no name

    In that directory, just should show echo hello-from-just and hello-from-just. If the first recipe takes a required parameter (build target:), bare just errors asking for it — that is the file-order limit, not a broken install.

Mark the recipe you actually want

Put [default] on dev, or a default recipe at the top that depends on lint/build/test. From just 1.52.0, set default-list := true makes a bare invocation list recipes instead of running one.

[default]
dev:
    echo starting server

lint:
    echo linting

# just.systems: set default-list := true  (1.52.0+)
# then bare just lists recipes instead of running one

The limit that bites

The mistake

Treating just --list as first success, or assuming a dev recipe later in the file is “the default.” Bare just does not guess your favorite.

A checkable first run

The output of a nameless just is the first recipe or [default]. Then hang the server there if you want. Script entrypoints: uv run.

Success is not “the justfile contains a dev line.” Success is that a coworker typing just with no args gets the command you intended.

Next: install just · uv run first · guide · start a room

Why does bare just fail if the first recipe has a parameter?

Recipes may take parameters. A nameless invocation calls the first or [default] recipe with no args. A required parameter then errors. Put a no-arg hello or [default] where a bare just can succeed.

Does just --list run commands?

No. It lists available recipes alphabetically. Use --unsorted for file order. Running still needs a recipe name or the default rule.

Can I run it from a subdirectory?

Yes. just walks upward to find a justfile and runs recipe lines in that file’s directory.

Does hereink ship just?

No. hereink is a temporary browser whiteboard. Open a room when a diagram needs a shared page; this site is not the just vendor.

Start a room