complete installed sub-commands
This commit is contained in:
parent
b9533ccac2
commit
5423f7fa2a
|
@ -390,6 +390,7 @@ esac
|
||||||
}
|
}
|
||||||
|
|
||||||
_cargo_cmds(){
|
_cargo_cmds(){
|
||||||
|
local IFS=$'\n'
|
||||||
local -a commands;commands=(
|
local -a commands;commands=(
|
||||||
'bench:execute all benchmarks of a local package'
|
'bench:execute all benchmarks of a local package'
|
||||||
'build:compile the current project'
|
'build:compile the current project'
|
||||||
|
@ -420,6 +421,7 @@ local -a commands;commands=(
|
||||||
'verify-project:check Cargo.toml'
|
'verify-project:check Cargo.toml'
|
||||||
'version:show version information'
|
'version:show version information'
|
||||||
'yank:remove pushed file from index'
|
'yank:remove pushed file from index'
|
||||||
|
$( cargo --list | sed -n '1!p' | tr -d ' ' | egrep -v "^bench$|^build$|^clean$|^doc$|^fetch$|^generate-lockfile$|^git-checkout$|^help$|^init$|^install$|^locate-project$|^login$|^metadata$|^new$|^owner$|^package$|^pkgid$|^publish$|^read-manifest$|^run$|^rustc$|^rustdoc$|^search$|^test$|^uninstall$|^update$|^verify-project$|^version$|^yank$" | sed -r "s/(.*)/echo \"\1:$\(cargo help \1 | head -n 1\)\"/" | sh )
|
||||||
)
|
)
|
||||||
_describe 'command' commands
|
_describe 'command' commands
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue