2
0
mirror of https://github.com/sharkdp/bat synced 2024-11-08 19:10:41 +00:00
Commit Graph

42 Commits

Author SHA1 Message Date
Oliver Kiddle
b43d31b75a Improvements and fixes to zsh completion
* Use correct return status so that approximate completion isn't broken
* Follow zsh conventions on description forms
* Some options can be used multiple times, e.g. -H, -r, --file-name
* Set completion context correctly for the cache subcommand
* Better completion for --map-syntax argument
* Add --nonprintable-notation option
* Correct some of the mutual exclusion lists for options
2023-12-01 11:11:44 +01:00
Maria José Solano
04e7d2a313 fix(completions): add missing fish completions 2023-11-04 08:51:13 +01: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
Adrián Bíro
e155f56484 Clean-up bash comletion
"cword" is unset and even is not used in completion for other shells, so it probably shouldn't be here either. If it for some reason should be there add the directive "# shellcheck disable=SC2034" to the line above it.
2023-05-12 05:59:36 +02:00
cyqsimon
b6b9d3a629
Disable completion of cache subcommand (#2399)
* Disable completion of `cache` subcommand

* Fully removed completion code for `cache`

* Add to changelog
2022-12-18 11:46:43 +01:00
Ville Skyttä
2dbc88d3af Improve bash completion escaping
`compopt -o filenames` is a cheap way to accomplish mostly wanted
behavior. However it is semantically incorrect when we are not actually
completing filenames, and has side effects -- for example adds a
trailing slash to candidates matching present dirs.

bash >= 4.1 can `printf -v` to an array index, use it instead where
available.
2022-09-11 21:54:22 +02:00
Ville Skyttä
66edfe5dff Exclude --unbuffered from bash completions
It's a no-op, so there's little reason to suggest it.
2022-09-11 21:54:22 +02:00
Ville Skyttä
c816188f97 Add --style argument bash completion 2022-09-11 21:54:22 +02:00
Ville Skyttä
46bf3c1e9a Do not offer bash filename completions with --list-languages/-themes 2022-09-11 21:54:22 +02:00
Ville Skyttä
066701d671 Add --acknowledgements and --ignored-suffix to bash completion 2022-09-11 21:54:22 +02:00
Ville Skyttä
e96cdc3b95 Split bash completion option lists over multiple lines, sync sort with --help
For maintainability/diffability.
2022-09-11 21:54:22 +02:00
Z. Grace Moreau
33ba136fa3 fix --pager opts display and add some examples 2022-08-27 16:37:34 +02:00
Z. Grace Moreau
f36df73ac1 add a vim modeline
This will cause vim (and other properly-extended editors) to read this
as a fish script file, despite its .fish.in extension.
2022-08-27 16:37:34 +02:00
Z. Grace Moreau
d14e0fe292 improve fish completions 2022-08-27 16:37:34 +02:00
Isaac Horvath
adea895026
Add a --style=default option (#2119)
* Add a --style=default option

* Added --style=default test and CHANGELOG entry

* Format CHANGELOG.md options with quotes

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

* Update help text for '--style'

* Make --style=default the default option

* Update style descriptions: "basic" -> "recommended"

* Add integration test for --style=default as default

* Update clap long help for --style
2022-05-04 21:31:32 +02:00
Martin Nordholts
3c057aa590 Add header-filename and header-filesize where missing 2022-02-27 07:39:22 +01:00
Josh Pencheon
ad6cae433a
fix Bash completion on macOS (#2074)
* fix Bash completion on macOS

The Homebrew-provided bash-completion is version 1.x,
which doesn't provide _init_completion. We add a standard
shim instead.

* Add entry to CHANGELOG

* Update CHANGELOG.md

Co-authored-by: Ville Skyttä <ville.skytta@iki.fi>

* review: avoid calling _split_longopt repeatedly

Co-authored-by: Ville Skyttä <ville.skytta@iki.fi>
2022-02-24 07:57:23 +01:00
NotWearingPants
6fc7ebf37a
Add missing style values in fish & zsh completions (#1890) 2021-10-11 19:13:16 +02:00
Rashil Gandhi
43afae34be
Add PowerShell completion file (#1826) 2021-08-28 13:39:17 +02:00
a1346054
51edacb5eb style: trim excess whitespace 2021-08-21 23:07:37 +02:00
Martin Nordholts
b040efff79 Support a hidden arg --no-custom-assets that skips loading assets from the cache 2021-07-29 08:27:02 +02:00
Ville Skyttä
8b37e62cf3 Add some more options to bash completion
https://github.com/sharkdp/bat/pull/1702#issuecomment-872452683
2021-07-01 22:47:00 +02:00
Frederick Zhang
42f1ef019a Fix missing config/cache arguments in Zsh completion 2021-06-28 11:59:01 +02:00
Ville Skyttä
06c601bc7c Depend on scop/bash-completion
For = option/arg separator support, improved mid-word completion
behavior, code cleanliness.
2021-06-28 11:58:03 +02:00
Ville Skyttä
229fbc1a18 Add missing comment about --theme arg escaping 2021-06-28 11:58:03 +02:00
Ville Skyttä
e05f5010da Add bash completion
Closes https://github.com/sharkdp/bat/issues/1010
2021-06-28 11:58:03 +02:00
Albert Safin
6bf7b79f13 Fix zsh completion
* Fix completion for -p option (#1320)
* Use prefixed function names to avoid name clash
2020-10-17 16:54:39 +02:00
Kienyew
a86f3e5b81 Fix packaging and Use parameterized names for zsh completion 2020-09-14 11:28:09 +02:00
Kienyew
8b0886ac32 Fix typo 2020-09-14 11:28:09 +02:00
Kienyew
41a1952928 use _describe instead of _values on subcommand 2020-09-14 11:28:09 +02:00
Kienyew
9885d4ebf0 add completion for 'cache' subcommand 2020-09-14 11:28:09 +02:00
Kienyew
222e080ce7 Fix character escape problem 2020-09-14 11:28:09 +02:00
Kienyew
046409d7c9 Add zsh completion 2020-09-14 11:28:09 +02:00
Dash Peters
c264f74771 Hide alias in help, update man and completions
A long alias doesn't make sense, since `--paging=never` already exists
2020-07-02 00:07:37 -07:00
Ethan P
ea2179b352
Update fish completions to use parameterized names 2019-09-27 12:13:55 -07:00
Ethan P
06b8dcb7eb Update fish completions for new --list-languages format 2019-05-14 22:50:42 +02:00
Ethan P
27e0ca98d9 Remove language completions for config files 2019-05-14 22:50:42 +02:00
Ethan P
1b2066c5f2 Add fish shell argument completions for --language option 2019-05-14 22:50:42 +02:00
evdev
cd6850947e Updated fish completions to include parameter completion for available themes, added cache subcommand completions 2019-04-13 10:59:22 +02:00
evdev
14bfedeb20 Updated fish completions to include parameter completion for flags: color, italic-text, decorations, paging, wrap 2019-04-13 10:59:22 +02:00
evdev
5e9351445f WIP: added manual minimal fish shell completions for current flags. Does not include flag sub-options like language lists or subcommands 2019-04-13 10:59:22 +02:00