Show More
@@ -24,8 +24,8 b' _ipython()' | |||
|
24 | 24 | { |
|
25 | 25 | local cur=${COMP_WORDS[COMP_CWORD]} |
|
26 | 26 | local prev=${COMP_WORDS[COMP_CWORD - 1]} |
|
27 | local subcommands="notebook qtconsole console kernel profile locate history nbconvert " | |
|
28 | local opts="" | |
|
27 | local subcommands="notebook qtconsole console kernel profile locate history nbconvert kernelspec " | |
|
28 | local opts="help" | |
|
29 | 29 | if [ -z "$__ipython_complete_baseopts" ]; then |
|
30 | 30 | _ipython_get_flags baseopts |
|
31 | 31 | __ipython_complete_baseopts="${opts}" |
@@ -53,10 +53,10 b' _ipython()' | |||
|
53 | 53 | "locate" | "profile") |
|
54 | 54 | _ipython_get_flags $mode |
|
55 | 55 | ;; |
|
56 | "history") | |
|
56 | "history" | "kernelspec") | |
|
57 | 57 | if [[ $COMP_CWORD -ge 3 ]]; then |
|
58 | 58 | # 'history trim' and 'history clear' covered by next line |
|
59 |
_ipython_get_flags |
|
|
59 | _ipython_get_flags $mode\ "${COMP_WORDS[2]}" | |
|
60 | 60 | else |
|
61 | 61 | _ipython_get_flags $mode |
|
62 | 62 | |
@@ -83,6 +83,15 b' _ipython()' | |||
|
83 | 83 | fi |
|
84 | 84 | local IFS=$'\t\n' |
|
85 | 85 | COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ) |
|
86 | elif [[ $mode == "kernelspec" ]]; then | |
|
87 | if [[ $COMP_CWORD -ge 3 ]]; then | |
|
88 | # drop into flags | |
|
89 | opts="--" | |
|
90 | else | |
|
91 | opts="list install " | |
|
92 | fi | |
|
93 | local IFS=$'\t\n' | |
|
94 | COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ) | |
|
86 | 95 | elif [[ $mode == "locate" ]]; then |
|
87 | 96 | opts="profile" |
|
88 | 97 | COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ) |
General Comments 0
You need to be logged in to leave comments.
Login now