mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-02-14 07:32:51 +08:00
Reformat share/{completions,functions}
This commit is contained in:
parent
f139d8ebed
commit
c12f853db2
|
@ -1,4 +1,3 @@
|
|||
|
||||
complete -c bru -s h -l help -d "Show help"
|
||||
complete -c bru -l version -d "Show version number"
|
||||
|
||||
|
|
|
@ -2,22 +2,22 @@
|
|||
|
||||
set -l subcmds prompt aliases chat collections embed embed-models embed-multi install keys logs models openai plugins similar templates uninstall
|
||||
function __fish_llm_subcmds
|
||||
printf "%s\t%s\n" "prompt" "Execute a prompt" \
|
||||
"aliases" "Manage model aliases" \
|
||||
"chat" "Hold chat with model" \
|
||||
"collections" "View/manage embedding collections" \
|
||||
"embed" "Embed text and get/store result" \
|
||||
"embed-models" "Manage available embedding models" \
|
||||
"embed-multi" "Store embeddings for multiple strings" \
|
||||
"install" "Install PyPI packages into llm env" \
|
||||
"keys" "Manage stored API keys" \
|
||||
"logs" "Explore logged prompts/responses" \
|
||||
"models" "Manage available models" \
|
||||
"openai" "Work with OpenAI API directly" \
|
||||
"plugins" "List installed plugins" \
|
||||
"similar" "Return top-N similar IDs for collection" \
|
||||
"templates" "Manage stored prompt templates" \
|
||||
"uninstall" "Uninstall Python packages from llm env"
|
||||
printf "%s\t%s\n" prompt "Execute a prompt" \
|
||||
aliases "Manage model aliases" \
|
||||
chat "Hold chat with model" \
|
||||
collections "View/manage embedding collections" \
|
||||
embed "Embed text and get/store result" \
|
||||
embed-models "Manage available embedding models" \
|
||||
embed-multi "Store embeddings for multiple strings" \
|
||||
install "Install PyPI packages into llm env" \
|
||||
keys "Manage stored API keys" \
|
||||
logs "Explore logged prompts/responses" \
|
||||
models "Manage available models" \
|
||||
openai "Work with OpenAI API directly" \
|
||||
plugins "List installed plugins" \
|
||||
similar "Return top-N similar IDs for collection" \
|
||||
templates "Manage stored prompt templates" \
|
||||
uninstall "Uninstall Python packages from llm env"
|
||||
end
|
||||
|
||||
complete -c llm -n __fish_is_first_token -xa "(__fish_llm_subcmds)"
|
||||
|
@ -45,7 +45,7 @@ end
|
|||
set -l condition "not __fish_seen_subcommand_from $subcmds || __fish_seen_subcommand_from prompt"
|
||||
complete -c llm -n $condition -s s -l system -d "System prompt to use" -r
|
||||
complete -c llm -n $condition -s m -l model -d "Model to use" -xa "(__fish_llm_models)"
|
||||
complete -c llm -n $condition -s a -l attachment -d "Attachment to use" -ra'-'
|
||||
complete -c llm -n $condition -s a -l attachment -d "Attachment to use" -ra-
|
||||
complete -c llm -n $condition -l at -d "Attachment type" -r
|
||||
complete -c llm -n $condition -l attachment-type -d "Attachment type" -r
|
||||
complete -c llm -n $condition -s n -l no-log -d "Don't log to db" -x
|
||||
|
|
|
@ -2,7 +2,6 @@ function __fish_ollama_list
|
|||
ollama list 2>/dev/null | tail -n +2 | string replace --regex "\s.*" ""
|
||||
end
|
||||
|
||||
|
||||
complete -f -c ollama
|
||||
complete -c ollama -n __fish_use_subcommand -a serve -d "Start ollama"
|
||||
complete -c ollama -n __fish_use_subcommand -a create -d "Create a model from a Modelfile"
|
||||
|
|
|
@ -11,4 +11,3 @@ else
|
|||
# is better than trying to write to /etc unexpectedly.
|
||||
rclone completion fish -
|
||||
end 2>/dev/null | source
|
||||
|
||||
|
|
|
@ -221,7 +221,7 @@ complete -c tmux -n "__fish_seen_subcommand_from $breakp $linkw $movew $neww $sw
|
|||
complete -c tmux -n "__fish_seen_subcommand_from $killw $lastp $nextl $prevl $renamew" -xs t -d 'target window'
|
||||
complete -c tmux -n "__fish_seen_subcommand_from $resizew $reswpawnw $rotatew $selectw $unlinkw" -xs t -d 'target window'
|
||||
complete -c tmux -n "__fish_seen_subcommand_from $displayp" -xs t -d 'target client'
|
||||
complete -c tmux -n "__fish_seen_subcommand_from $lsp" -xs t -d 'target'
|
||||
complete -c tmux -n "__fish_seen_subcommand_from $lsp" -xs t -d target
|
||||
|
||||
############### End: Windows and Panes ###############
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user