You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
compdef _func new can use func's completion for the new command. However the new cannot be an alias when complete_aliases is not set. It's because the alias will be expanded before invoking completion function and the original command will be completed instead. Use function instead of alias to make the compdef work.
Press ^X? (Ctrl+X ?) instead of Tab to run _complete_debug. This places a trace of the completion code into a file which you can view by pressing Up Enter. Alternatively, if you want to generate a trace of a specific function while you're debugging it, add this to the beginning of your function to get an execution trace:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Completion
compdef _func newcan usefunc's completion for thenewcommand. However thenewcannot be an alias whencomplete_aliasesis not set. It's because the alias will be expanded before invoking completion function and the original command will be completed instead. Use function instead of alias to make thecompdefwork.ref
Press
^X?(Ctrl+X ?) instead of Tab to run _complete_debug. This places a trace of the completion code into a file which you can view by pressing Up Enter. Alternatively, if you want to generate a trace of a specific function while you're debugging it, add this to the beginning of your function to get an execution trace:ref
Use
echo ${_comps[brew]}to check the completion function of a command.Beta Was this translation helpful? Give feedback.
All reactions