add base setup with dotter

This commit is contained in:
Alexander Navarro 2024-11-08 22:53:56 +00:00 committed by aleidk
parent 6b0da868bb
commit 42e6595b60
177 changed files with 1062 additions and 70 deletions

View file

@ -0,0 +1,47 @@
#compdef tldr
_applications() {
local -a commands
commands=(${(uonzf)"$(tldr --list 2>/dev/null)"//:/\\:})
_describe -t commands 'command' commands
}
_tealdeer() {
local I="-h --help -v --version"
integer ret=1
local -a args
args+=(
"($I -l --list)"{-l,--list}"[List all commands in the cache]"
"($I -f --render)"{-f,--render}"[Render a specific markdown file]:file:_files"
"($I -p --platform)"{-p,--platform}'[Override the operating system]:platform:((
linux
macos
sunos
windows
android
))'
"($I -L --language)"{-L,--language}"[Override the language settings]:lang"
"($I -u --update)"{-u,--update}"[Update the local cache]"
"($I)--no-auto-update[If auto update is configured, disable it for this run]"
"($I -c --clear-cache)"{-c,--clear-cache}"[Clear the local cache]"
"($I)--pager[Use a pager to page output]"
"($I -r --raw)"{-r,--raw}"[Display the raw markdown instead of rendering it]"
"($I -q --quiet)"{-q,--quiet}"[Suppress informational messages]"
"($I)--show-paths[Show file and directory paths used by tealdeer]"
"($I)--seed-config[Create a basic config]"
"($I)--color[Controls when to use color]:when:((
always
auto
never
))"
'(- *)'{-h,--help}'[Display help]'
'(- *)'{-v,--version}'[Show version information]'
'1: :_applications'
)
_arguments $args[@] && ret=0
return ret
}
_tealdeer