mirror of
https://github.com/Llewellynvdm/exa.git
synced 2024-11-22 20:15:11 +00:00
6eb5cee634
This removes the "raw" man pages and converts them to Markdown, adding a build step using pandoc that converts them. Having the man pages in Markdown makes them much, much easier to write and keep updated, at the cost of not having the raw formats easily available. Hopefully having the command to generate them in the Justfile will be enough. It also splits out the EXA_COLORS environment variable into its own page, because it took up just under half of the one for the exa binary.
43 lines
1.0 KiB
Bash
43 lines
1.0 KiB
Bash
_exa()
|
|
{
|
|
cur=${COMP_WORDS[COMP_CWORD]}
|
|
prev=${COMP_WORDS[COMP_CWORD-1]}
|
|
|
|
case "$prev" in
|
|
-'?'|--help|-v|--version)
|
|
return
|
|
;;
|
|
|
|
-L|--level)
|
|
COMPREPLY=( $( compgen -W '{0..9}' -- "$cur" ) )
|
|
return
|
|
;;
|
|
|
|
-s|--sort)
|
|
COMPREPLY=( $( compgen -W 'name filename Name Filename size filesize extension Extension date time modified changed accessed created type inode oldest newest age none --' -- "$cur" ) )
|
|
return
|
|
;;
|
|
|
|
-t|--time)
|
|
COMPREPLY=( $( compgen -W 'modified changed accessed created --' -- $cur ) )
|
|
return
|
|
;;
|
|
|
|
--time-style)
|
|
COMPREPLY=( $( compgen -W 'default iso long-iso full-iso --' -- $cur ) )
|
|
return
|
|
;;
|
|
esac
|
|
|
|
case "$cur" in
|
|
-*)
|
|
COMPREPLY=( $( compgen -W '$( _parse_help "$1" )' -- "$cur" ) )
|
|
;;
|
|
|
|
*)
|
|
_filedir
|
|
;;
|
|
esac
|
|
} &&
|
|
complete -o filenames -o bashdefault -F _exa exa
|