mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-10-23 04:30:24 +02:00
Chris Lamb: 26655: complete custom Django management commands.
This commit is contained in:
parent
05a7f19f69
commit
e47333d0a9
2 changed files with 15 additions and 1 deletions
|
@ -57,6 +57,15 @@ case $state in
|
|||
"testserver:run a development server with data from the given fixture(s)"
|
||||
"validate:validate all installed modules"
|
||||
)
|
||||
|
||||
for cmd in $(./manage.py --help 2>&1 >/dev/null | \
|
||||
awk -vdrop=1 '{ if (!drop) print substr($0, 3) } /^Available subcommands/ { drop=0 }')
|
||||
do
|
||||
if ! echo $subcommands | grep -qs "${cmd}:"
|
||||
then
|
||||
subcommands+=($cmd)
|
||||
fi
|
||||
done
|
||||
|
||||
_describe -t subcommands 'django admin subcommand' subcommands && ret=0
|
||||
;;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue