* [PATCH 1/2] run-help: chain run-help-sudo to call run-help on the next argument
@ 2018-12-27 15:24 Samir Benmendil
2018-12-27 15:24 ` [PATCH 2/2] run-help: add run-help-btrfs Samir Benmendil
0 siblings, 1 reply; 2+ messages in thread
From: Samir Benmendil @ 2018-12-27 15:24 UTC (permalink / raw)
To: zsh-workers; +Cc: Samir Benmendil
---
Functions/Misc/run-help-sudo | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Functions/Misc/run-help-sudo b/Functions/Misc/run-help-sudo
index f38696e19..a8fa7aa0f 100644
--- a/Functions/Misc/run-help-sudo
+++ b/Functions/Misc/run-help-sudo
@@ -2,6 +2,6 @@
if [ $# -eq 0 ]; then
man sudo
else
- man $1
+ run-help $1
fi
--
2.19.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* [PATCH 2/2] run-help: add run-help-btrfs
2018-12-27 15:24 [PATCH 1/2] run-help: chain run-help-sudo to call run-help on the next argument Samir Benmendil
@ 2018-12-27 15:24 ` Samir Benmendil
0 siblings, 0 replies; 2+ messages in thread
From: Samir Benmendil @ 2018-12-27 15:24 UTC (permalink / raw)
To: zsh-workers; +Cc: Samir Benmendil
---
Functions/Misc/run-help-btrfs | 31 +++++++++++++++++++++++++++++++
1 file changed, 31 insertions(+)
create mode 100644 Functions/Misc/run-help-btrfs
diff --git a/Functions/Misc/run-help-btrfs b/Functions/Misc/run-help-btrfs
new file mode 100644
index 000000000..d9e3530c1
--- /dev/null
+++ b/Functions/Misc/run-help-btrfs
@@ -0,0 +1,31 @@
+if [ $# -eq 0 ]; then
+ man btrfs
+ return
+fi
+
+while [[ $# != 0 && $1 == -* ]]; do
+ shift
+done
+
+case $1 in
+ (b*) man btrfs-balance ;;
+ (c*) man btrfs-check ;;
+ (d*) man btrfs-device ;;
+ (f*) man btrfs-filesystem ;;
+ (i*) man btrfs-image ;;
+ (i*) man btrfs-inspect-internal ;;
+ (m*) man btrfs-map-logical ;;
+ (p*) man btrfs-property ;;
+ (q*) man btrfs-qgroup ;;
+ (q*) man btrfs-quota ;;
+ (rec*) man btrfs-receive ;;
+ (rep*) man btrfs-replace ;;
+ (resc*) man btrfs-rescue ;;
+ (rest*) man btrfs-restore ;;
+ (sc*) man btrfs-scrub ;;
+ (se*) man btrfs-send ;;
+ (su*) man btrfs-subvolume ;;
+ (*) man btrfs ;;
+esac
+
+return $?
--
2.19.1
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, back to index
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-27 15:24 [PATCH 1/2] run-help: chain run-help-sudo to call run-help on the next argument Samir Benmendil
2018-12-27 15:24 ` [PATCH 2/2] run-help: add run-help-btrfs Samir Benmendil
zsh-workers
Archives are clonable: git clone --mirror http://inbox.vuxu.org/zsh-workers
Newsgroup available over NNTP:
nntp://inbox.vuxu.org/vuxu.archive.zsh.workers
AGPL code for this site: git clone https://public-inbox.org/ public-inbox