mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-10-07 12:06:22 +00:00
feat(opencode): add completion and opc aliases
This commit is contained in:
1 parent
d217d05374
commit
333e42b5af
3 files changed
+124
No files matched your search
@@ -0,0 +1,12 @@
|
||||
#compdef opencode
|
||||
|
||||
# Adapted from `opencode completion`, using the CLI's live Yargs completions.
|
||||
local -a reply
|
||||
reply=("${(@f)$(COMP_CWORD="$((CURRENT-1))" COMP_LINE="$BUFFER" COMP_POINT="$CURSOR" \
|
||||
command opencode --get-yargs-completions "${words[@]}" < /dev/null 2> /dev/null)}")
|
||||
|
||||
if [[ -n "${reply[1]}" ]]; then
|
||||
_describe 'values' reply
|
||||
else
|
||||
_default
|
||||
fi
|
||||
Reference in new issue
Block a user