Commit Graph

15 Commits

Author SHA1 Message Date
Casey Rodarmor
5995221555
Change dotenv-load default to false (#1082)
This changes the default value of `dotenv-load` from `true` to `false`. This
is a backwards incompatible change, and will require a minor version bump.
2022-02-02 03:16:35 +00:00
Casey Rodarmor
0ae91884e2
Add --dump-format json (#992) 2021-11-17 00:07:48 -08:00
Casey Rodarmor
629c75ff04
Use stable rustfmt instead of nightly (#967) 2021-09-16 13:44:40 +00:00
Casey Rodarmor
27cf2b96df
Use ColorDisplay trait to print objects to the terminal (#926) 2021-07-29 01:06:57 +00:00
Casey Rodarmor
1f20ca6481
Warn if .env file is loaded in dotenv-load isn't explicitly set (#925)
If a `.env` file is found and loaded, but the `dotenv-load` setting hasn't been explicitly
set to true, print a warning to stderr. In approximately six months, `dotenv-load` will
change from defaulting to true to defaulting to false, which will be a potentially breaking
change in behavior for justfiles which elicit this warning.

See this issue for more details:

    https://github.com/casey/just/issues/469
2021-07-28 07:33:44 +00:00
Casey Rodarmor
1b0fafea75
Add loader and refactor errors (#917)
This commit adds a `Loader` type, which can be used to load multiple
source strings. This was done to support the work on modules, but
coincidentally enabled consolidating errors, since now `Config::run`
can take a `&Loader`, and in the event of an error, return and `Error`
that borrows from loaded strings. Multiple error types have been
consolidated, and a bunch of ad-hoc error printing was removed.
2021-07-26 01:26:06 -07:00
Oleksii Dorozhkin
8677492d56
Add --fmt subcommand (#837) 2021-06-08 01:01:27 -07:00
Casey Rodarmor
a1a016b4e0
Disable .env warning for now 2021-03-30 17:59:15 -07:00
Casey Rodarmor
e4ebf6dad9
Warn if .env file loaded and dotenv-load unset (#784) 2021-03-30 17:30:32 -07:00
Casey Rodarmor
10282bd636
Turn = deprecation warning into a hard error (#780)
It's been around two and a half years, and many versions, since this
warning was first introduced, so it feels reasonable to finally turn it
into a hard error. It will remain a special-cased error for a little
while.
2021-03-28 23:39:23 -07:00
Casey Rodarmor
3ec7dea4a3
Use unstable rustfmt configuration options (#592) 2020-02-10 20:07:06 -08:00
Casey Rodarmor
598f1c3200
Refactor Compilation error to contain a Token (#535)
Use a `Token` to represent the error context, instead of a mess of
fields. Remove write_message_context in favor of `Token::write_context`.
2019-11-13 19:32:50 -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
Casey Rodarmor
3de31b3c02
Remove misc.rs (#491)
Put everything that was in `misc.rs` into their own files, with some opportunistic
refactoring, because why not.
2019-10-09 01:40:40 -07:00
Casey Rodarmor
1230af138c
Add context to deprecation warnings (#473)
Previously, warnings upon encountering a deprecated use `=` in
assignments, exports, and aliases would print a message without any
indication of where the offending `=` was. This diff adds a proper
`Warning` enum, and uses it to report context, as is done with
compilation and runtime errors.
2019-09-21 18:53:30 -07:00