chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a50df72
)
zsh-completions: kernel-install - only show existing kernels for 'remove'
author
Tom Gundersen
<teg@jklm.no>
Thu, 6 Feb 2014 17:15:47 +0000
(18:15 +0100)
committer
Tom Gundersen
<teg@jklm.no>
Fri, 7 Feb 2014 14:48:35 +0000
(15:48 +0100)
When we remove a kernel, we don't remove the modules, so don't look at the modules directory to find installed kernels.
shell-completion/zsh/_kernel-install
patch
|
blob
|
history
diff --git
a/shell-completion/zsh/_kernel-install
b/shell-completion/zsh/_kernel-install
index 065518834c1b98d4072409198d590902b78e4a43..4fdd3a4ae7cec5afee20033f34fdac27348bb17b 100644
(file)
--- a/
shell-completion/zsh/_kernel-install
+++ b/
shell-completion/zsh/_kernel-install
@@
-12,7
+12,7
@@
_kernels(){
read _MACHINE_ID < /etc/machine-id
_kernel=( /lib/modules/[0-9]* )
if [[ "$cmd" == "remove" && -n "$_MACHINE_ID" ]]; then
- _kernel=(
/lib/modules/[0-9]*
"/boot/$_MACHINE_ID"/[0-9]* )
+ _kernel=( "/boot/$_MACHINE_ID"/[0-9]* )
fi
_kernel=( ${_kernel##*/} )
_describe "installed kernels" _kernel