Staging
v0.5.1
swh:1:snp:c5feb7ee9221a3820c8879e85e8a18470c0b3afa
Raw File
Tip revision: c7c84859ad586ae5670224e1abc4f846f7c3a9ae authored by Junio C Hamano on 16 June 2007, 06:58:18 UTC
GIT 1.5.2.2
Tip revision: c7c8485
generate-cmdlist.sh
#!/bin/sh

echo "/* Automatically generated by $0 */
struct cmdname_help
{
    char name[16];
    char help[80];
};

struct cmdname_help common_cmds[] = {"

sort <<\EOF |
add
apply
archive
bisect
branch
checkout
cherry-pick
clone
commit
diff
fetch
grep
init
log
merge
mv
prune
pull
push
rebase
reset
revert
rm
show
show-branch
status
tag
EOF
while read cmd
do
     sed -n '
     /NAME/,/git-'"$cmd"'/H
     ${
            x
            s/.*git-'"$cmd"' - \(.*\)/  {"'"$cmd"'", "\1"},/
	    p
     }' "Documentation/git-$cmd.txt"
done
echo "};"
back to top