Skip to contentSkip to conversation

Group common commands into for groups for easier navigation

PATCH New [email protected] 1 participant 2 messages Aug 11, 2016 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH 2/3 Prepare for grouped common command list generation

---
 generate-cmdlist.sh |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
generate-cmdlist.sh +6 -1
index 5450918..b45495d 100755
@@ -9,7 +9,7 @@ struct cmdname_help
 
 struct cmdname_help common_cmds[] = {"
 
-sort <<\EOF |
+cat <<\EOF |
 add
 apply
 archive
@@ -41,6 +41,11 @@ verify-tag
 EOF
 while read cmd
 do
+     [ -z "$cmd" ] && continue
+     if echo $cmd|grep -q '^G:'; then
+       echo '  {"'$(echo -n $cmd|sed 's/^G://')'",""},'
+       continue
+     fi
      sed -n '
      /NAME/,/git-'"$cmd"'/H
      ${
Signature · 1 line
1.4.4.rc1.g9124
#2 lore raw

PATCH 3/3 Group common commands into for groups for easier navigation

Repository/Branch level commands are grouped into group Repository File manipulation commands are in group Manipulation Other status commands are in group Status
The rest is in group Other

---
This is a suggestion. Someone may have better layout than me.

 generate-cmdlist.sh |   35 +++++++++++++++++++++--------------
 1 files changed, 21 insertions(+), 14 deletions(-)
generate-cmdlist.sh +21 -14
index b45495d..f385854 100755
@@ -10,33 +10,40 @@ struct cmdname_help
 struct cmdname_help common_cmds[] = {"
 
 cat <<\EOF |
-add
-apply
-archive
-bisect
+G:Repository
+init-db
 branch
-checkout
-cherry-pick
 clone
-commit
-diff
 fetch
-grep
-init-db
-log
 merge
-mv
 prune
 pull
 push
-rebase
 reset
+tag
+
+G:Manipulation
+add
+apply
+checkout
+commit
+mv
 revert
 rm
+
+G:Status
+diff
+log
 show
 show-branch
 status
-tag
+
+G:Other
+archive
+bisect
+cherry-pick
+grep
+rebase
 verify-tag
 EOF
 while read cmd
Signature · 1 line
1.4.4.rc1.g9124