Commit Graph

31 Commits (bc2dc0796b9632a494b714019c65d38b333f16e8)

Author SHA1 Message Date
Martin Nordholts 2dd2994b2f Merge remote-tracking branch 'origin/master' into feature/668/add-systemwide-config 2 years ago
Christopher Acosta 9a924b445b
Make --map-syntax and --ignored-suffix work together (#2260)
* Make --map-syntax and --ignored-suffix work together

* Minor refactor
2 years ago
Keith Hall b5294f1cb2
Skip syntax highlighting for long lines (#2165)
* Skip highlighting for long lines

* Run cargo fmt, update changelog
2 years ago
Patrick Pichler 6b660ef63a Add test for systemwide config file support
There is now a new stage in the CICD workflow present, which will build
`bat` with the `BAT_SYSTEM_CONFIG_PREFIX` set to load the config file
from `/tests/examples/system_config/bat/config`, plus a basic set of
tests, to ensure the feature is working as expected. By default the
tests are set to ignored, as they need special setup before they can be
run.
3 years ago
cyqsimon 14ddda0a8b
Recognize files in `$XDG_CONFIG_HOME/git/` and `$HOME/.config/git/` better (#2067)
* git global config - lookup $XDG_CONFIG_HOME faithfully

* Use `bool::then`

* Cover both `$XDG_CONFIG_HOME` & `$HOME/.config`

* Remove unused import

* Global git config tests

* Added trailing newline

* Fix git config test

* Wrote to changelog

* Revert change of `Result::ok` to `Result::unwrap`

* Apply suggestions from code review

Co-authored-by: Martin Nordholts <enselic@gmail.com>

* Guard against empty `$HOME`

Co-authored-by: Martin Nordholts <enselic@gmail.com>
3 years ago
Bojan Đurđević d6ed5e6746
Support for ignored-suffix CLI arguments (#1892) 3 years ago
Martin Nordholts 9ed9a6fc3d
Simplify HighlightingAssets::get_syntax() first_line logic (#1852)
And make self.get_first_line_syntax() be called lazily.
3 years ago
Niklas Mohrin b8a18d3ebb Use tempfiles for clircle tests 4 years ago
Niklas Mohrin ace655e164 Add integration tests for clircle cycle detection 4 years ago
sharkdp bd2e9917da Revert "Add cycle detection integration tests"
This reverts commit ec60d84265.
4 years ago
Niklas Mohrin 4f0116bee7 Add cycle detection integration tests 4 years ago
Evgeniy Andreev (gsomix) 3c5ce9f86c Enable non-printable chars for redirected output (#1061) 4 years ago
Roy Ivy III 71ab4a2058 Tests ~ revert to `echo` (after fixed 'windows' pager process execution) 4 years ago
Roy Ivy III 3a7743ffc5 Tests ~ `echo` has portability issues; for CI, replace with `printf`
- using `echo` on 'windows' platforms requires process execution indirectly via the shell
- `printf` is available on all GHA CI platforms
  - `printf` is *not* available on usual 'windows' platforms; so this is just temporizing, awaiting a true fix
4 years ago
Ethan P 82981c9663
Add regression test for detected syntax differing for stdin and files 4 years ago
sharkdp 5449472f15 Remove invalid UTF-8 file from repo, use temp file instead 4 years ago
sharkdp 82e20bfe14 Fix bug for file with invalid-utf8 filenames 4 years ago
sharkdp 03c2281828 Add do-not-panic! regression tests 4 years ago
Kyle Criddle cfa2cb6ec7 --file-name for normal files. integration tests. 5 years ago
Kogia-sima 60f48a0c91 Update test data
Avoid using existing text
5 years ago
Kogia-sima 22ded00824 Add test for unicode wrapping 5 years ago
sharkdp 2e71146801 Fix another instance of the 'bat cache' bug, closes #584 5 years ago
sharkdp 72152296c7 Fix accidental printing of files named 'cache'
This also adds two regression tests, so this will hopefully not pop up
again.

closes #557
5 years ago
sharkdp fa3244f7c1 Add test for UTF-16LE encoding 6 years ago
sharkdp 906774e6d3 Integration tests for single-line files 6 years ago
Reid Wagner cec9cc073c Add integration tests running bat with empty input files. 6 years ago
sharkdp 278d841408 Move '--paging' arg to config file. 6 years ago
Ricky 558134f6c8 Changed to unwrap methods, added integration tests 6 years ago
Lawrence Chou 76e34b29ec Avoid empty line in snapshot 6 years ago
Lawrence Chou 58198d0700 rewrite 6 snapshot tests as integration test 6 years ago
sharkdp 1891e194b5 Add simple integration tests 6 years ago