mirror of
https://github.com/sharkdp/bat.git
synced 2025-03-15 15:18:45 +00:00
Added batlog alias for reading logfiles
This commit is contained in:
parent
b35a74b73a
commit
4170d9b0f2
10
README.md
10
README.md
@ -162,6 +162,16 @@ batgrep needle src/
|
|||||||
```bash
|
```bash
|
||||||
tail -f /var/log/pacman.log | bat --paging=never -l log
|
tail -f /var/log/pacman.log | bat --paging=never -l log
|
||||||
```
|
```
|
||||||
|
You can also add an alias `batlog`` to read any logfile
|
||||||
|
|
||||||
|
```bash
|
||||||
|
alias batlog='bat --paging=never -l log'
|
||||||
|
|
||||||
|
tail -f /var/log/pacman.log | batlog
|
||||||
|
|
||||||
|
batlog /var/log/pacman.log
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
Note that we have to switch off paging in order for this to work. We have also specified the syntax
|
Note that we have to switch off paging in order for this to work. We have also specified the syntax
|
||||||
explicitly (`-l log`), as it can not be auto-detected in this case.
|
explicitly (`-l log`), as it can not be auto-detected in this case.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user