pyflakes: New completion
This commit is contained in:
parent
e452f2e8d6
commit
e14617e498
@ -283,6 +283,7 @@ bashcomp_DATA = 2to3 \
|
||||
pwdx \
|
||||
pwgen \
|
||||
pydoc \
|
||||
pyflakes \
|
||||
pylint \
|
||||
python \
|
||||
qdbus \
|
||||
|
23
completions/pyflakes
Normal file
23
completions/pyflakes
Normal file
@ -0,0 +1,23 @@
|
||||
# pyflakes(1) completion -*- shell-script -*-
|
||||
|
||||
_pyflakes()
|
||||
{
|
||||
local cur prev words cword
|
||||
_init_completion || return
|
||||
|
||||
case $prev in
|
||||
-h|--help|--version)
|
||||
return
|
||||
;;
|
||||
esac
|
||||
|
||||
if [[ $cur == -* ]]; then
|
||||
COMPREPLY=( $( compgen -W '$( _parse_help "$1" )' -- "$cur" ) )
|
||||
return
|
||||
fi
|
||||
|
||||
_filedir py
|
||||
} &&
|
||||
complete -F _pyflakes pyflakes
|
||||
|
||||
# ex: ts=4 sw=4 et filetype=sh
|
1
test/completion/pyflakes.exp
Normal file
1
test/completion/pyflakes.exp
Normal file
@ -0,0 +1 @@
|
||||
assert_source_completions pyflakes
|
18
test/lib/completions/pyflakes.exp
Normal file
18
test/lib/completions/pyflakes.exp
Normal file
@ -0,0 +1,18 @@
|
||||
proc setup {} {
|
||||
save_env
|
||||
}
|
||||
|
||||
|
||||
proc teardown {} {
|
||||
assert_env_unmodified
|
||||
}
|
||||
|
||||
|
||||
setup
|
||||
|
||||
|
||||
assert_complete_any "pyflakes "
|
||||
sync_after_int
|
||||
|
||||
|
||||
teardown
|
Loading…
x
Reference in New Issue
Block a user