Commit graph

23 commits

Author SHA1 Message Date
Amaan Qureshi
5ea0dbf77a chore: some more clippy lints 2024-02-13 03:33:07 -05:00
Amaan Qureshi
21f25a5305 feat: improve error message for files with an unknown grammar path 2024-02-12 17:17:37 -05:00
Amaan Qureshi
4149ed4149 chore: provide a CLI flag to open log.html
On macOS, this was done by default regardless of what the user wants.
This was also not done on Windows or Linux. Instead, we now provide a
`--open-log` flag to open the log file in the default browser, and it
works on all platforms.
2024-02-11 02:28:34 -05:00
Amaan Qureshi
7980669267 feat: support dot graph output on windows 2024-02-08 15:21:47 -05:00
Amaan Qureshi
04ff704bca
chore(cli): apply clippy fixes 2024-02-04 04:18:48 -05:00
Andrew Hlynskyi
e966c5ad5b fix: use SIGINT instead of stdin for interruption to don't mess up piped commands 2023-05-02 10:43:46 +03:00
Max Brunsfeld
125503ff3b Fix CLI build on windows 2023-02-13 23:40:06 -08:00
Max Brunsfeld
97fd990822 Add --dot flag to parse subcommand, for printing tree as DOT graph 2023-02-13 12:33:34 -08:00
Andrew Helwer
993e93eeee Fix linux build 2021-09-28 19:06:05 -04:00
Andrew Helwer
3b5f9cb642 Fixed cargo fmt 2021-09-28 18:53:24 -04:00
Andrew Helwer
8eef790a61 Build rust with warnings=errors 2021-09-28 18:51:09 -04:00
Douglas Creager
d2d01e77e3 cli: Use anyhow and thiserror for errors
This patch updates the CLI to use anyhow and thiserror for error
management.  The main feature that our custom `Error` type was providing
was a _list_ of messages, which would allow us to annotate "lower-level"
errors with more contextual information.  This is exactly what's
provided by anyhow's `Context` trait.

(This is setup work for a future PR that will pull the `config` and
`loader` modules out into separate crates; by using `anyhow` we wouldn't
have to deal with a circular dependency between with the new crates.)
2021-06-09 16:17:23 -04:00
Max Brunsfeld
08d17e33bd Fix unused import warning on windows 2021-03-11 16:43:20 -08:00
Max Brunsfeld
b972a7158d Tweak cancellation logic for CLI commands
In 'parse' and 'highlight' cancel on stdin if stdin is a tty.
2020-10-23 12:15:44 -07:00
Max Brunsfeld
0bfd47e2e5 Improve error message when failing to run graphviz stuff
Fixes #682
2020-07-10 10:13:19 -07:00
Max Brunsfeld
783c087aec tags: Handle cancellation 2020-03-25 11:26:52 -07:00
Max Brunsfeld
4cac85fec4 Add benchmark script
* Structure `cli` crate as both a library and an executable, so that
benchmarks can import code from the crate.
* Import macros in the Rust 2018 style.
2019-02-01 15:17:35 -08:00
Max Brunsfeld
6105bf9909 Include error recovery examples in test suite 2019-01-20 16:58:49 -08:00
Max Brunsfeld
ed195de8b6 rustfmt 2019-01-17 17:16:04 -08:00
Max Brunsfeld
ef735eb942 Upload binary artifacts from CI builds 2019-01-16 10:12:43 -08:00
Max Brunsfeld
5c3c1dd0bd Get logging flags working properly with test script 2019-01-15 13:21:48 -08:00
Max Brunsfeld
ae6dbb945b Avoid using unix-specific methods on windows 2019-01-10 16:11:19 -08:00
Max Brunsfeld
98807d2053 Add debug and debug-graph flags to parse and test commands 2019-01-08 21:03:51 -08:00