Harrison McCullough
cf7b33443a
Add --less-search-pattern option to tell less to search for pattern
...
The `less` pager can search for a pattern. In addition, you can instruct it to
search for a given pattern on startup by passing in the `-p` flag followed by
the pattern to search for. Since the `batgrep` command is searching for a
pattern and invoking the pager, it has the opportunity to take advantage of this
functionality.
This patch adds a `-p` flag to `batgrep` which, in turn, passes `-p $PATTERN` to
the pager invoked. This may be specific to `less`, which is
unfortunate. However, it doesn't seem like there would be a convenient way to
make this more general. In addition, most pagers forward the actual paging to
`less` anyways.
To clarify that the behavior is specific to `less`, the long name is
`--less-search-pattern`.
2020-01-17 10:25:38 -05:00
Ethan P
285ac66303
Fix missing pager arguments in batman.sh
2019-12-23 17:08:32 -08:00
Ethan P
18bf6e2c5c
Add argument forwarding from batgrep to ripgrep
2019-12-23 16:58:58 -08:00
Ethan P
a3483a658a
Add support for '--smart-case' to batgrep
2019-12-23 16:49:31 -08:00
Ethan P
e967497387
Update batman.sh to use the pager.sh library script
2019-12-23 16:39:33 -08:00
Ethan P
7cabaa620d
Fix batman.sh incorrectly disabling the pager
2019-12-23 16:20:28 -08:00
Ethan P
767cfb59b0
Update batwatch to use print_error function
2019-10-25 13:52:44 -07:00
Ethan P
80a07980aa
Add "poll" watcher to batwatch
2019-10-25 13:50:10 -07:00
Ethan P
d9e34e2d5f
Add color option to batman
2019-10-22 15:35:10 -07:00
Ethan P
763d34d9c9
Fix LIB variable
2019-10-22 15:04:34 -07:00
Ethan P
93843cd067
Fix missing file name in batwatch
2019-10-11 12:18:43 -07:00
Ethan P
0621d14951
Add ClangFormat to prettybat
2019-09-26 18:02:21 -07:00
Ethan P
24313f8281
Fix broken error message in batwatch
2019-09-26 16:10:42 -07:00
Ethan P
33ebf07bbd
Update batwatch to show errors outside the pager
2019-09-26 16:08:44 -07:00
Ethan P
e02d0666f3
Add batwatch script
2019-09-26 15:36:38 -07:00
Ethan P
a472f1c651
Refactor common messages into functions
2019-09-25 15:59:54 -07:00
Ethan P
9c10ef4871
Refactor common options into opt hooks
2019-09-25 14:48:21 -07:00
Ethan P
d776b7acbc
Misc fixes for code formatting/style
2019-09-25 13:20:36 -07:00
Ethan P
e71de135e6
Add experimental pager support to batgrep
2019-09-24 12:10:17 -07:00
Ethan P
c8e22890fe
Update batgrep to disabled highlights when -C=0
2019-09-18 21:12:23 -07:00
Ethan P
daa54ba4cf
Update batgrep to allow snip to be disabled
2019-09-18 14:20:04 -07:00
Ethan P
3d4a0b8381
Add support for building with alternate executable names
2019-09-08 17:43:29 -07:00
Ethan P
85bb5f8bed
Added script for using bat with man
2019-09-07 15:19:12 -07:00
Ethan P
b09f38190c
Updated batgrep to use the new bat 0.12 "snip" component
2019-09-06 18:05:19 -07:00
Ethan P
1c9eb2cb82
Fixed snapshot tests on CI... hopefully
2019-07-26 15:34:48 -07:00
Ethan P
882f438e50
Fixed batgrep incorrect highlighting
2019-07-26 14:50:09 -07:00
Ethan P
5f248064e0
Fixed prettybat formatter mappings
2019-06-21 16:17:20 -07:00
Ethan P
09604dbefc
Added rust support to prettybat
2019-06-21 15:47:23 -07:00
Ethan P
16ea5cc401
Refactored prettybat to be more modular
2019-06-21 15:42:48 -07:00
Ethan P
147c823c1d
Fixed highlighting with prettybat
2019-06-21 14:48:21 -07:00
Ethan P
ce0c2a57f1
Added prettybat
2019-06-21 14:22:42 -07:00
Ethan P
2633149c04
Fixed batgrep using the pager for bat.
2019-06-19 17:33:06 -07:00
Ethan P
248d7077f4
Initial commit.
2019-06-19 14:15:10 -07:00