diff options
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | Completion/Unix/Command/_sh | 3 | ||||
-rw-r--r-- | Completion/Unix/Type/_cmdstring | 6 | ||||
-rw-r--r-- | Completion/Zsh/Command/_emulate | 6 |
4 files changed, 18 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog index ee6860c0c..269fa3932 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2015-01-30 Peter Stephenson <p.stephenson@samsung.com> + + * 34435: Completion/Unix/Command/_sh, + Completion/Unix/Type/_cmdstring, Completion/Zsh/Command/_emulate: + updated emulate completion; _cmdstring factors out use of + quoted command string. + 2015-01-29 Peter Stephenson <p.w.stephenson@ntlworld.com> * 34430: Src/Modules/db_gdbm.c, Src/params.c: various bug fixes diff --git a/Completion/Unix/Command/_sh b/Completion/Unix/Command/_sh index 104c7576c..21ebfc3b2 100644 --- a/Completion/Unix/Command/_sh +++ b/Completion/Unix/Command/_sh @@ -10,8 +10,7 @@ if [[ $service == zsh ]]; then fi if (( CURRENT == ${words[(i)-c]} + 1 )); then - compset -q - _normal + _cmdstring else local n=${words[(b:2:i)[^-]*]} if (( n <= CURRENT )); then diff --git a/Completion/Unix/Type/_cmdstring b/Completion/Unix/Type/_cmdstring new file mode 100644 index 000000000..fb19fdb76 --- /dev/null +++ b/Completion/Unix/Type/_cmdstring @@ -0,0 +1,6 @@ +#autoload + +# This is for a quoted argument that will be interpreted as a command. + +compset -q +_normal diff --git a/Completion/Zsh/Command/_emulate b/Completion/Zsh/Command/_emulate index e562d6834..d6fb0c3d9 100644 --- a/Completion/Zsh/Command/_emulate +++ b/Completion/Zsh/Command/_emulate @@ -1,6 +1,8 @@ #compdef emulate -_arguments -C -s -A "-*" \ +_arguments -C -s \ '-L[set local_options and local_traps as well]' \ '-R[reset all options instead of only those needed for script portability]' \ - '::shell to emulate:(zsh sh ksh csh)' + '1:shell to emulate:(zsh sh ksh csh)' \ + '2:specify optional command:(-c)' \ + '3:command:_cmdstring' |