Commit Graph

21 Commits

Author SHA1 Message Date
Greg Shuflin
38873dcb74
Allow unexporting environment variables (#2098) 2024-06-05 20:16:47 +00:00
Casey Rodarmor
f2201d8684
Add set dotenv-required to require an environment file (#2116) 2024-05-30 23:12:07 +00:00
Casey Rodarmor
b1c7491486
Add shell-expanded strings (#2055) 2024-05-19 05:41:38 +00:00
Elizaveta Demina
9aea3e679b
Add assert expression (#1845) 2024-05-15 01:55:32 +00:00
Markus
e11684008e
Add 'allow-duplicate-variables' setting (#1922) 2024-05-15 01:39:42 +00:00
David Harrigan
5bbc89b718
Add set quiet and [no-quiet] (#1704) 2024-01-12 20:38:23 +00:00
Casey Rodarmor
316ea01295
Add modules (#1782) 2023-12-28 04:27:15 +00:00
Casey Rodarmor
e9bec8d398
Stabilize !include path as import 'path' (#1771) 2023-12-20 12:31:51 +08:00
Laurent Fourrier
812e1ea3cc
Add dotenv-filename and dotenv-path settings (#1692) 2023-10-12 05:04:46 +00:00
David Matos
beeaa6ce2d Add tempdir setting (#1369) 2022-10-25 16:57:32 -07:00
Casey Rodarmor
28be873dfc
Require set fallback := true to enable recipe fallback (#1368) 2022-10-19 19:00:09 -07:00
Greg Shuflin
e445cfb47d
Add skip-comments setting (#1333)
Add a new setting "skip-comments", which defaults to true. If unset,
this causes lines internal to a non-shebang recipe beginning with the
character '#' (including '#!' internal to a non-shebang recipe; that is,
any such instances occurring after the first line of a recipe) to be
treated as comments of the justfile itself. They will not be echoed to
stderr when the recipe executes.
2022-10-05 00:32:30 +00:00
Casey Rodarmor
01fae9b1e4
Do use super::*; instead of use crate::common::*; (#1239) 2022-06-19 04:56:31 +00:00
Casey Rodarmor
c24a194602
Add windows-shell setting (#1198) 2022-05-31 13:01:59 -07:00
Greg Lutostanski
bcdaa95a66
Allow duplicate recipes (#1095) 2022-02-15 02:37:06 +00:00
Michael Lohr
6cf95a7337
Add windows-powershell setting (#1057) 2022-01-18 19:02:15 +00:00
Casey Rodarmor
67bd318bf9
Add positional-arguments setting (#804)
Allow recipe arguments to be passed as positional arguments to commands.
2021-04-24 18:29:58 -07:00
Casey Rodarmor
18b9799e8d
Add dotenv-load setting (#778)
The `dotenv-load` setting controls whether or not a `.env` file will be
loaded if present. It currently defaults to true.
2021-03-28 22:38:07 -07:00
Casey Rodarmor
19f7ad09a7
Add conditional expressions (#714)
Add conditional expressions of the form:

   foo := if lhs == rhs { then } else { otherwise }

`lhs`, `rhs`, `then`, and `otherwise` are all arbitrary expressions, and
can recursively include other conditionals. Conditionals short-circuit,
so the branch not taken isn't evaluated.

It is also possible to test for inequality with `==`.
2020-10-26 18:16:42 -07:00
Casey Rodarmor
e80bf34d9a
Add shell setting (#525)
Add a `set SETTING := VALUE` construct.

This construct is intended to be extended as needed with new settings,
but for now we're starting with `set shell := [COMMAND, ARG1, ...]`,
which allows setting the shell to use for recipe and backtick execution
in a justfile.

One of the primary reasons for adding this feature is to have a better
story on windows, where users are forced to scrounge up an `sh` binary
if they want to use `just`. This should allow them to use cmd.exe or
powershell in their justfiles, making just optionally dependency-free.
2019-11-10 23:17:47 -08:00
Casey Rodarmor
b2285ce0e0
Reform Parser (#509)
Just's first parser performed both parsing, i.e the transformation of a
token stream according to the language grammar, and a number of consistency
checks and analysis passes.

This made parsing and analysis quite complex, so this diff introduces a
new, much cleaner `Parser`, and moves existing analysis into a dedicated
`Analyzer`.
2019-11-07 10:55:15 -08:00