Keith Hall
7d37325c19
Fix to not show style decorations in auto mode when piping
2025-11-30 05:02:13 +02:00
Muntasir Mahmud
70ec3fc24e
feat: add paging to '-h' and '--help' ( #3478 )
...
* feat: add paging to '-h' and '--help'
Fixes #1587
2025-11-23 20:10:56 +00:00
Louis Maddox
7eedc0f854
feat(pipe-style): make output pipeable (any style)
2025-10-18 10:29:39 +01:00
Keith Hall
2badaf5d99
cargo fmt
2025-10-08 22:45:50 +03:00
Keith Hall
588ff32d18
Fix help/version/diagnostic commands with invalid config
2025-10-08 22:45:50 +03:00
Yuri Astrakhan
503c50b1ec
chore: address all cargo clippy lints
...
* also do a bit of a doc cleanup for the `load_from_folder` fn
2025-08-19 05:22:47 +02:00
cyqsimon
555933315d
Only start offload worker thread when there's more than 1 core ( #2956 )
...
* Only start offload worker thread when there's more than 1 core
* Write changelog
2025-07-15 05:21:00 +02:00
einfachIrgendwer0815
12a2a451b4
Add paging to --list-themes
2025-04-02 11:27:37 +02:00
einfachIrgendwer0815
cc46282866
Fix clippy::into_iter_on_ref warnings
2025-02-02 15:08:13 +01:00
Keith Hall
60693db73f
Merge branch 'master' into dark-light
2024-11-13 20:33:37 +02:00
einfachIrgendwer0815
3b71837174
Merge branch 'master' into fix/2731_plain_override
2024-10-30 13:06:13 +01:00
einfachIrgendwer0815
c9fd0f3cf0
Add partial override of -pp and --paging
2024-10-18 12:13:41 +02:00
Tau Gärtli
50958472e5
Return theme alongside detected color scheme
2024-08-23 18:03:07 +02:00
Tau Gärtli
bc42149a72
Merge color scheme options into theme / BAT_THEME
2024-08-18 14:59:14 +02:00
einfachIrgendwer0815
7f089ead62
Add option --binary
...
`--binary` allows to specify how to deal with binary content. Current
options are not printing anything or treating the binary data as text.
2024-08-18 10:05:37 +02:00
Tau Gärtli
b9b981f657
Generalize --detect-color-scheme to --color-scheme
2024-08-16 14:14:30 +02:00
Tau Gärtli
5c6974703e
Respect --detect-color-scheme flag when listing themes
2024-08-16 14:13:58 +02:00
Tau Gärtli
ff81cfd584
Move actual detection into library
2024-08-16 14:13:16 +02:00
Tau Gärtli
cea45e05f3
Expose new theme selection in CLI
2024-08-16 14:12:22 +02:00
Ethan P.
aa3ec109b7
First StyleComponentList should remove from 'auto' style.
...
This happens when there are no `--style` arguments other than the one
passed in as a command line argument.
Prior to this change, removing a style component (e.g. `--style=-numbers`)
would remove the component from an empty style component set, resulting
in no styles at all. That behaviour was less intuitive than the new
behaviour, which starts out with the default components and
removes the line numbers.
2024-07-30 21:22:02 -07:00
Ethan P.
b74c125c43
Support merging --style arguments
...
The `overrides_with` clap builder option was removed
because it interfered with the matcher's ability to
retain all occurrences of `--style`.
The behavior it covered is expressed within the new
`forced_style_components` function.
2024-07-30 21:21:53 -07:00
Ethan P.
9e8176b1c6
Add --strip-ansi=auto option
...
When using `auto`, escape sequences will be stripped unless printing
plain text.
2024-06-17 18:27:33 -07:00
Ethan P.
70ff93d238
Add --strip-ansi option
2024-06-16 16:49:07 -07:00
David Peter
f29f9387b5
Merge pull request #2868 from cyqsimon/builtin-offload-v2
...
Faster startup by offloading glob matcher building to a worker thread
2024-03-10 20:08:43 +01:00
einfachIrgendwer0815
83b00bc653
Rename --squeeze to --squeeze-blank
2024-02-24 14:02:27 +01:00
Ethan P
0e4e10edb6
Add --squeeze-limit to specify max number of consecutive empty lines
...
Co-authored-by: einfachIrgendwer0815 <85333734+einfachIrgendwer0815@users.noreply.github.com >
2024-02-24 13:51:06 +01:00
Ethan P
c36ed32816
Add --squeeze/-s option
...
Co-authored-by: einfachIrgendwer0815 <85333734+einfachIrgendwer0815@users.noreply.github.com >
2024-02-24 13:51:00 +01:00
cyqsimon
2b4339663c
Builtin glob matchers build offload, v2
2024-02-21 14:56:37 +08:00
Oliver Looney
c3f2ddf509
Merge branch 'master' into 2783-setting-terminal-title
2024-02-11 22:53:48 +00:00
Oliver looney
7ce010d9ed
Using hypens instead of underscores for set-terminal-title command
2024-02-08 21:33:03 +00:00
Oliver looney
9239b125b1
added a flag to config for setting terminal title
2024-01-27 14:14:40 +00:00
cyqsimon
e4d637a3d8
Reverse precedence of syntax mappings specified on CLI
2024-01-18 22:41:57 +08:00
cyqsimon
cfd622d6e1
Migrate SyntaxMapping impl to new system
...
Most existing builtins are removed but not yet ported, so the test
`user_can_override_builtin_mappings` should fail. It should pass once the old
rules have been ported.
2023-12-11 10:21:05 +08:00
Lena
28990bc451
fix: display color when NO_COLOR is an empty string ( #2767 )
2023-12-02 11:43:55 +00:00
Anomalocaridid
b56021ffa9
make LESSOPEN support opt-in
2023-09-08 06:25:20 +02:00
Anomalocaridid
e32ad0b048
Add $LESSOPEN and $LESSCLOSE support ( #2444 )
2023-09-02 08:48:26 +02:00
mataha
82664e3c82
Bump MSRV to 1.70.0
...
The intention is to take advantage of `std::io::IsTerminal` that landed
in 1.70.0, both in `bat` and its dependencies (`clap`, `grep-cli`).
This will fix #2570 as well - `grep-cli` 0.1.9 has a patch for that.
Signed-off-by: mataha <mataha@users.noreply.github.com >
2023-09-01 05:42:45 +02:00
Nigecat
149dec6953
Fix paging not happening when stdout is interactive but stdin is not
2023-05-22 05:42:01 +02:00
Constantin Nickel
57cc0d8435
Use the is-terminal crate instead of atty
...
The crate is already used by `clap` and a similar trait is about to be
stabilized in `std`.
2023-04-05 19:26:52 +02:00
Constantin Nickel
da3aa4e2fd
Use nu-ansi-term instead of ansi_term
...
The `nu-ansi-term` crate is a fork of `ansi_term` which is maintained by
the Nushell project.
2023-03-24 17:42:54 +01:00
einfachIrgendwer0815
8f99a78cf1
Print non-printable characters using caret notation ( #2443 )
...
When the new flag is set, non-printable characters are printed using caret notation.
2023-03-14 22:21:30 +01:00
Aaron Kollasch
e773b48135
Fix cache subcommand and add tests
...
Treat the cache subcommand differently from --no-config:
For --no-config, insert args from selected environment variables
For cache, don't insert args
2022-11-02 16:48:51 -04:00
Aaron Kollasch
4bcea01e9d
Deduplicate lines in matches function
2022-11-02 16:48:51 -04:00
Aaron Kollasch
76aad7c74f
Improve correctness and add more tests
2022-11-02 16:48:50 -04:00
Aaron Kollasch
36ccc6a31e
Allow env vars to override config but not args
2022-11-02 16:48:50 -04:00
David Peter
a65b0828ee
Merge remote-tracking branch 'origin/master' into HEAD
2022-10-30 20:43:06 +01:00
John Higgins
236a2c5794
Fixed inverted logic on -S and --chop-long-lines
2022-10-13 23:52:15 -07:00
John Higgins
375b392478
Fixed reversed logic error for --chop-long-lines
2022-10-09 22:41:27 -07:00
Gábor Lipták
1e0b0f7c5c
Add github-actions to Dependabot
...
Signed-off-by: Gábor Lipták <gliptak@gmail.com >
2022-10-03 15:18:39 -05:00
John Higgins
a272d3df16
Added -S flag for truncating long lines
2022-09-09 17:04:09 -07:00