projects
/
grml-etc-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e07e9a2
)
zshrc: vman: Handle zero arguments [Closes: issue993]
author
Frank Terbeck
<ft@grml.org>
Thu, 26 May 2011 19:16:00 +0000
(21:16 +0200)
committer
Frank Terbeck
<ft@grml.org>
Thu, 26 May 2011 19:16:00 +0000
(21:16 +0200)
etc/zsh/zshrc
patch
|
blob
|
history
diff --git
a/etc/zsh/zshrc
b/etc/zsh/zshrc
index
03e272d
..
a68687f
100644
(file)
--- a/
etc/zsh/zshrc
+++ b/
etc/zsh/zshrc
@@
-3711,7
+3711,11
@@
show-archive() {
#f5# Use \kbd{vim} as your manpage reader
vman() {
emulate -L zsh
- man $* | col -b | view -c 'set ft=man nomod nolist' -
+ if (( ${#argv} == 0 )); then
+ printf 'usage: vman <topic>\n'
+ return 1
+ fi
+ man "$@" | col -b | view -c 'set ft=man nomod nolist' -
}
# function readme() { $PAGER -- (#ia3)readme* }