Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Variables and Assignments

Module-level variables may be created by assigning them a value with :=:

foo := "hello"
bar := "world"

baz:
  echo {{ foo + " " + bar }}

All variables in a module may be printed:

$ just --evaluate
bar := "world"
foo := "hello"

Or the value of a single variable:

$ just --evaluate foo
hello

All variables in a submodule or a single variable in a submodule may be printed with a path to the submodule or variable1.49.0:

$ just --evaluate bob::bar
x := "world"
y := "hello"
$ just --evaluate bob::bar::y
hello

The format of exported variables may be controlled with --evaluate-format1.49.0:

$ just --evaluate --evaluate-format shell
bar="world"
foo="hello"

The default format is --evaluate-format just:

$ just --evaluate --evaluate-format just
bar := "world"
foo := "hello"