{"thread":{"id":"3612","subject":"[PATCH 0/3] Make the output of 'git' nicer","startedAt":"2006-03-09T16:17:22Z","lastAt":"2006-03-09T17:32:04Z","messageCount":6,"participants":["Fredrik Kuivinen","Jan-Benedict Glaw","Ryan Anderson"],"isPatch":true,"patchVersion":1,"patchTotal":3},"messages":[{"id":"17379","messageId":"20060309161722.GA4484@c165.ib.student.liu.se","threadId":"3612","inReplyTo":null,"subject":"[PATCH 0/3] Make the output of 'git' nicer","fromName":"Fredrik Kuivinen","fromEmail":"freku045@student.liu.se","sentAt":"2006-03-09T16:17:22Z","receivedAt":"2006-03-09T16:17:22Z","isPatch":true,"sender":{"key":"frekui@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13770967?v=4"},"body":"Hi,\n\nThis series makes the output of 'git' easier to read (IMHO). With this\npatch the output will look like this:\n\n\nUsage: git [--version] [--exec-path[=GIT_EXEC_PATH]] [--help] COMMAND [ ARGS ]\n\nThe most commonly used git commands are:\n    add            Add files to the index file\n    apply          Apply patch on a git index file and a work tree\n    bisect         Find the change that introduced a bug\n    branch         Create a new branch, or remove an old one\n    checkout       Checkout and switch to a branch\n    cherry-pick    Apply the change introduced by an existing commit\n    clone          Clones a repository\n    commit         Record your changes\n    diff           Show changes between commits, commit and working tree, etc\n    fetch          Download objects and a head from another repository\n    grep           Print lines matching a pattern\n    init-db        Creates an empty git repository\n    log            Show commit logs\n    merge          Grand Unified Merge Driver\n    mv             Move or rename a file, directory or symlink\n    prune          Prunes all unreachable objects from the object database\n    pull           Pull and merge from another repository\n    push           Update remote refs along with associated objects\n    rebase         Rebase local commits to new upstream head\n    reset          Reset current HEAD to the specified state\n    revert         Revert an existing commit\n    rm             Remove files from the working tree and from the index\n    show-branch    Show branches and their commits\n    status         Show working tree status\n    tag            Create a tag object signed with GPG\n    verify-tag     Check the GPG signature of tag\n    whatchanged    Show logs with difference each commit introduces\n(use 'git help -a' to get a list of all installed git commands)\n\n- Fredrik\n"},{"id":"17382","messageId":"20060309162419.GB4484@c165.ib.student.liu.se","threadId":"3612","inReplyTo":"20060309161722.GA4484@c165.ib.student.liu.se","subject":"[PATCH 1/3] Nicer output from 'git'","fromName":"Fredrik Kuivinen","fromEmail":"freku045@student.liu.se","sentAt":"2006-03-09T16:24:19Z","receivedAt":"2006-03-09T16:24:19Z","isPatch":true,"sender":{"key":"frekui@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13770967?v=4"},"body":"\nSigned-off-by: Fredrik Kuivinen <freku045@student.liu.se>\n\n\n---\n\n .gitignore            |    1 +\n Documentation/git.txt |   11 ++++++-----\n Makefile              |    7 +++++--\n generate-cmdlist.sh   |   22 ++++++++++++++++++++++\n git.c                 |   50 +++++++++++++++++++++++++++++++++++++------------\n 5 files changed, 72 insertions(+), 19 deletions(-)\n\ndiff --git a/.gitignore b/.gitignore\nindex abbc509..8e94cbd 100644\n--- a/.gitignore\n+++ b/.gitignore\n@@ -121,6 +121,7 @@ git-write-tree\n git-core-*/?*\n test-date\n test-delta\n+common-cmds.h\n *.tar.gz\n *.dsc\n *.deb\ndiff --git a/Documentation/git.txt b/Documentation/git.txt\nindex 2d0ca9d..8610d36 100644\n--- a/Documentation/git.txt\n+++ b/Documentation/git.txt\n@@ -20,15 +20,16 @@ brings your stuff to the plumbing).\n OPTIONS\n -------\n --version::\n-\tprints the git suite version that the 'git' program came from.\n+\tPrints the git suite version that the 'git' program came from.\n \n --help::\n-\tprints the synopsis and a list of available commands.\n-\tIf a git command is named this option will bring up the\n-\tman-page for that command.\n+\tPrints the synopsis and a list of the most commonly used\n+\tcommands.  If a git command is named this option will bring up\n+\tthe man-page for that command. If the option '--all' or '-a' is\n+\tgiven then all available commands are printed.\n \n --exec-path::\n-\tpath to wherever your core git programs are installed.\n+\tPath to wherever your core git programs are installed.\n \tThis can also be controlled by setting the GIT_EXEC_PATH\n \tenvironment variable. If no path is given 'git' will print\n \tthe current setting and then exit.\ndiff --git a/Makefile b/Makefile\nindex 1c555da..dc9a742 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -452,10 +452,13 @@ all:\n strip: $(PROGRAMS) git$X\n \t$(STRIP) $(STRIP_OPTS) $(PROGRAMS) git$X\n \n-git$X: git.c $(LIB_FILE)\n+git$X: git.c common-cmds.h $(LIB_FILE)\n \t$(CC) -DGIT_VERSION='\"$(GIT_VERSION)\"' \\\n \t\t$(ALL_CFLAGS) -o $@ $(filter %.c,$^) $(LIB_FILE) $(LIBS)\n \n+common-cmds.h: Documentation/git-*.txt\n+\t./generate-cmdlist.sh > $@\n+\n $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh\n \trm -f $@\n \tsed -e '1s|#!.*/sh|#!$(SHELL_PATH_SQ)|' \\\n@@ -612,7 +615,7 @@ rpm: dist\n clean:\n \trm -f *.o mozilla-sha1/*.o arm/*.o ppc/*.o compat/*.o $(LIB_FILE)\n \trm -f $(ALL_PROGRAMS) git$X\n-\trm -f *.spec *.pyc *.pyo */*.pyc */*.pyo\n+\trm -f *.spec *.pyc *.pyo */*.pyc */*.pyo common-cmds.h\n \trm -rf $(GIT_TARNAME)\n \trm -f $(GIT_TARNAME).tar.gz git-core_$(GIT_VERSION)-*.tar.gz\n \t$(MAKE) -C Documentation/ clean\ndiff --git a/generate-cmdlist.sh b/generate-cmdlist.sh\nnew file mode 100755\nindex 0000000..02091b5\n--- /dev/null\n+++ b/generate-cmdlist.sh\n@@ -0,0 +1,22 @@\n+#!/bin/sh\n+\n+echo \"/* Automatically generated by $0 */\n+struct cmdname_help \n+{\n+    char name[16];\n+    char help[64];\n+};\n+\n+struct cmdname_help common_cmds[] = {\"\n+\n+# Please keep this list sorted\n+for i in \"add\" \"apply\" \"bisect\" \"branch\" \"checkout\" \"cherry-pick\" \"clone\" \\\n+\"commit\" \"diff\" \"fetch\" \"grep\" \"init-db\" \"log\" \"merge\" \"mv\" \\\n+\"prune\" \"pull\" \"push\" \"rebase\" \"reset\" \"revert\" \"rm\" \"show-branch\" \\\n+\"status\" \"tag\" \"verify-tag\" \"whatchanged\"\n+do\n+    sed -n \"/NAME/,/git-$i/H;\n+\t    \\$ {x; s/.*git-$i - \\\\(.*\\\\)/{\\\"$i\\\", \\\"\\1\\\"},/; p}\" \\\n+\t\"Documentation/git-$i.txt\"\n+done\n+echo \"};\"\ndiff --git a/git.c b/git.c\nindex 164d3e9..2cbb471 100644\n--- a/git.c\n+++ b/git.c\n@@ -11,6 +11,7 @@\n #include <sys/ioctl.h>\n #include \"git-compat-util.h\"\n #include \"exec_cmd.h\"\n+#include \"common-cmds.h\"\n \n #include \"cache.h\"\n #include \"commit.h\"\n@@ -171,11 +172,29 @@ static void list_commands(const char *ex\n \tputchar('\\n');\n }\n \n+static void list_common_cmds_help()\n+{\n+\tint i, longest = 0;\n+\n+\tfor(i = 0; i < sizeof(common_cmds)/sizeof(struct cmdname_help); i++) {\n+\t\tif(strlen(common_cmds[i].name) > longest)\n+\t\t\tlongest = strlen(common_cmds[i].name);\n+\t}\n+\n+\tputs(\"The most commonly used git commands are:\");\n+\tfor(i = 0; i < sizeof(common_cmds)/sizeof(struct cmdname_help); i++) {\n+\t\tprintf(\"    %s\", common_cmds[i].name);\n+\t\tmput_char(' ', longest - strlen(common_cmds[i].name) + 4);\n+\t\tputs(common_cmds[i].help);\n+\t}\n+\tputs(\"(use 'git help -a' to get a list of all installed git commands)\");\n+}\n+\n #ifdef __GNUC__\n-static void cmd_usage(const char *exec_path, const char *fmt, ...)\n-\t__attribute__((__format__(__printf__, 2, 3), __noreturn__));\n+static void cmd_usage(int show_all, const char *exec_path, const char *fmt, ...)\n+\t__attribute__((__format__(__printf__, 3, 4), __noreturn__));\n #endif\n-static void cmd_usage(const char *exec_path, const char *fmt, ...)\n+static void cmd_usage(int show_all, const char *exec_path, const char *fmt, ...)\n {\n \tif (fmt) {\n \t\tva_list ap;\n@@ -189,11 +208,14 @@ static void cmd_usage(const char *exec_p\n \telse\n \t\tputs(git_usage);\n \n-\tputchar('\\n');\n-\n-\tif(exec_path)\n-\t\tlist_commands(exec_path, \"git-*\");\n-\n+\tif(exec_path) {\n+\t\tputchar('\\n');\n+\t\tif(show_all)\n+\t\t\tlist_commands(exec_path, \"git-*\");\n+\t\telse\n+\t\t\tlist_common_cmds_help();\n+        }\n+        \n \texit(1);\n }\n \n@@ -244,8 +266,12 @@ static int cmd_help(int argc, const char\n {\n \tconst char *help_cmd = argv[1];\n \tif (!help_cmd)\n-\t\tcmd_usage(git_exec_path(), NULL);\n-\tshow_man_page(help_cmd);\n+\t\tcmd_usage(0, git_exec_path(), NULL);\n+\telse if(!strcmp(help_cmd, \"--all\") ||\n+\t\t!strcmp(help_cmd, \"-a\"))\n+\t\tcmd_usage(1, git_exec_path(), NULL);\n+\telse\n+\t\tshow_man_page(help_cmd);\n \treturn 0;\n }\n \n@@ -420,7 +446,7 @@ int main(int argc, const char **argv, ch\n \t\t\tputs(git_exec_path());\n \t\t\texit(0);\n \t\t}\n-\t\tcmd_usage(NULL, NULL);\n+\t\tcmd_usage(0, NULL, NULL);\n \t}\n \targv[0] = cmd;\n \n@@ -443,7 +469,7 @@ int main(int argc, const char **argv, ch\n \texecv_git_cmd(argv);\n \n \tif (errno == ENOENT)\n-\t\tcmd_usage(exec_path, \"'%s' is not a git-command\", cmd);\n+\t\tcmd_usage(0, exec_path, \"'%s' is not a git-command\", cmd);\n \n \tfprintf(stderr, \"Failed to run command '%s': %s\\n\",\n \t\tgit_command, strerror(errno));\n"},{"id":"17380","messageId":"20060309162436.GC4484@c165.ib.student.liu.se","threadId":"3612","inReplyTo":"20060309161722.GA4484@c165.ib.student.liu.se","subject":"[PATCH 2/3] Fix some inconsistencies in the docs","fromName":"Fredrik Kuivinen","fromEmail":"freku045@student.liu.se","sentAt":"2006-03-09T16:24:37Z","receivedAt":"2006-03-09T16:24:37Z","isPatch":true,"sender":{"key":"frekui@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13770967?v=4"},"body":"Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>\n\n\n---\n\n Documentation/git-grep.txt |    2 +-\n Documentation/git-mv.txt   |    2 +-\n Documentation/git-tag.txt  |    2 +-\n 3 files changed, 3 insertions(+), 3 deletions(-)\n\ndiff --git a/Documentation/git-grep.txt b/Documentation/git-grep.txt\nindex bf4b592..fbd2394 100644\n--- a/Documentation/git-grep.txt\n+++ b/Documentation/git-grep.txt\n@@ -3,7 +3,7 @@ git-grep(1)\n \n NAME\n ----\n-git-grep - print lines matching a pattern\n+git-grep - Print lines matching a pattern\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-mv.txt b/Documentation/git-mv.txt\nindex d242b39..21a8664 100644\n--- a/Documentation/git-mv.txt\n+++ b/Documentation/git-mv.txt\n@@ -3,7 +3,7 @@ git-mv(1)\n \n NAME\n ----\n-git-mv - Script used to move or rename a file, directory or symlink.\n+git-mv - Move or rename a file, directory or symlink.\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-tag.txt b/Documentation/git-tag.txt\nindex e1c76c6..45476c2 100644\n--- a/Documentation/git-tag.txt\n+++ b/Documentation/git-tag.txt\n@@ -3,7 +3,7 @@ git-tag(1)\n \n NAME\n ----\n-git-tag -  Create a tag object signed with GPG\n+git-tag - Create a tag object signed with GPG\n \n \n SYNOPSIS\n"},{"id":"17381","messageId":"20060309162450.GD4484@c165.ib.student.liu.se","threadId":"3612","inReplyTo":"20060309161722.GA4484@c165.ib.student.liu.se","subject":"[PATCH 3/3] Remove trailing dot after short description","fromName":"Fredrik Kuivinen","fromEmail":"freku045@student.liu.se","sentAt":"2006-03-09T16:24:50Z","receivedAt":"2006-03-09T16:24:50Z","isPatch":true,"sender":{"key":"frekui@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13770967?v=4"},"body":"Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>\n\n\n---\n\n Documentation/git-add.txt               |    2 +-\n Documentation/git-applypatch.txt        |    2 +-\n Documentation/git-branch.txt            |    2 +-\n Documentation/git-check-ref-format.txt  |    2 +-\n Documentation/git-checkout.txt          |    2 +-\n Documentation/git-cherry-pick.txt       |    2 +-\n Documentation/git-cherry.txt            |    2 +-\n Documentation/git-clone-pack.txt        |    2 +-\n Documentation/git-clone.txt             |    2 +-\n Documentation/git-count-objects.txt     |    2 +-\n Documentation/git-daemon.txt            |    2 +-\n Documentation/git-describe.txt          |    2 +-\n Documentation/git-diff-stages.txt       |    2 +-\n Documentation/git-diff.txt              |    2 +-\n Documentation/git-fetch-pack.txt        |    2 +-\n Documentation/git-fetch.txt             |    2 +-\n Documentation/git-format-patch.txt      |    2 +-\n Documentation/git-get-tar-commit-id.txt |    2 +-\n Documentation/git-hash-object.txt       |    2 +-\n Documentation/git-http-push.txt         |    2 +-\n Documentation/git-lost-found.txt        |    2 +-\n Documentation/git-ls-remote.txt         |    2 +-\n Documentation/git-ls-tree.txt           |    2 +-\n Documentation/git-mailinfo.txt          |    2 +-\n Documentation/git-mailsplit.txt         |    2 +-\n Documentation/git-mv.txt                |    2 +-\n Documentation/git-name-rev.txt          |    2 +-\n Documentation/git-pack-objects.txt      |    2 +-\n Documentation/git-pack-redundant.txt    |    2 +-\n Documentation/git-patch-id.txt          |    2 +-\n Documentation/git-peek-remote.txt       |    2 +-\n Documentation/git-pull.txt              |    2 +-\n Documentation/git-push.txt              |    2 +-\n Documentation/git-rebase.txt            |    2 +-\n Documentation/git-relink.txt            |    2 +-\n Documentation/git-repo-config.txt       |    2 +-\n Documentation/git-request-pull.txt      |    2 +-\n Documentation/git-reset.txt             |    2 +-\n Documentation/git-rev-parse.txt         |    2 +-\n Documentation/git-revert.txt            |    2 +-\n Documentation/git-rm.txt                |    2 +-\n Documentation/git-send-pack.txt         |    2 +-\n Documentation/git-sh-setup.txt          |    2 +-\n Documentation/git-shortlog.txt          |    2 +-\n Documentation/git-show-branch.txt       |    2 +-\n Documentation/git-show.txt              |    2 +-\n Documentation/git-status.txt            |    2 +-\n Documentation/git-stripspace.txt        |    2 +-\n Documentation/git-unpack-objects.txt    |    2 +-\n Documentation/git-upload-pack.txt       |    2 +-\n Documentation/git-verify-pack.txt       |    2 +-\n Documentation/git-verify-tag.txt        |    2 +-\n Documentation/git-whatchanged.txt       |    2 +-\n 53 files changed, 53 insertions(+), 53 deletions(-)\n\ndiff --git a/Documentation/git-add.txt b/Documentation/git-add.txt\nindex 5b7c354..ae24547 100644\n--- a/Documentation/git-add.txt\n+++ b/Documentation/git-add.txt\n@@ -3,7 +3,7 @@ git-add(1)\n \n NAME\n ----\n-git-add - Add files to the index file.\n+git-add - Add files to the index file\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-applypatch.txt b/Documentation/git-applypatch.txt\nindex 5b9037d..2b1ff14 100644\n--- a/Documentation/git-applypatch.txt\n+++ b/Documentation/git-applypatch.txt\n@@ -3,7 +3,7 @@ git-applypatch(1)\n \n NAME\n ----\n-git-applypatch - Apply one patch extracted from an e-mail.\n+git-applypatch - Apply one patch extracted from an e-mail\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-branch.txt b/Documentation/git-branch.txt\nindex b1bc827..4cd0cb9 100644\n--- a/Documentation/git-branch.txt\n+++ b/Documentation/git-branch.txt\n@@ -3,7 +3,7 @@ git-branch(1)\n \n NAME\n ----\n-git-branch - Create a new branch, or remove an old one.\n+git-branch - Create a new branch, or remove an old one\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-check-ref-format.txt b/Documentation/git-check-ref-format.txt\nindex f7f84c6..7dc1bdb 100644\n--- a/Documentation/git-check-ref-format.txt\n+++ b/Documentation/git-check-ref-format.txt\n@@ -3,7 +3,7 @@ git-check-ref-format(1)\n \n NAME\n ----\n-git-check-ref-format - Make sure ref name is well formed.\n+git-check-ref-format - Make sure ref name is well formed\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-checkout.txt b/Documentation/git-checkout.txt\nindex df9a618..556e733 100644\n--- a/Documentation/git-checkout.txt\n+++ b/Documentation/git-checkout.txt\n@@ -3,7 +3,7 @@ git-checkout(1)\n \n NAME\n ----\n-git-checkout - Checkout and switch to a branch.\n+git-checkout - Checkout and switch to a branch\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-cherry-pick.txt b/Documentation/git-cherry-pick.txt\nindex 4f323fa..bfa950c 100644\n--- a/Documentation/git-cherry-pick.txt\n+++ b/Documentation/git-cherry-pick.txt\n@@ -3,7 +3,7 @@ git-cherry-pick(1)\n \n NAME\n ----\n-git-cherry-pick - Apply the change introduced by an existing commit.\n+git-cherry-pick - Apply the change introduced by an existing commit\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-cherry.txt b/Documentation/git-cherry.txt\nindex af87966..9a5e371 100644\n--- a/Documentation/git-cherry.txt\n+++ b/Documentation/git-cherry.txt\n@@ -3,7 +3,7 @@ git-cherry(1)\n \n NAME\n ----\n-git-cherry - Find commits not merged upstream.\n+git-cherry - Find commits not merged upstream\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-clone-pack.txt b/Documentation/git-clone-pack.txt\nindex 39906fc..09f43ee 100644\n--- a/Documentation/git-clone-pack.txt\n+++ b/Documentation/git-clone-pack.txt\n@@ -3,7 +3,7 @@ git-clone-pack(1)\n \n NAME\n ----\n-git-clone-pack - Clones a repository by receiving packed objects.\n+git-clone-pack - Clones a repository by receiving packed objects\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-clone.txt b/Documentation/git-clone.txt\nindex 684e4bd..9ac54c2 100644\n--- a/Documentation/git-clone.txt\n+++ b/Documentation/git-clone.txt\n@@ -3,7 +3,7 @@ git-clone(1)\n \n NAME\n ----\n-git-clone - Clones a repository.\n+git-clone - Clones a repository\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-count-objects.txt b/Documentation/git-count-objects.txt\nindex 36888d9..47216f4 100644\n--- a/Documentation/git-count-objects.txt\n+++ b/Documentation/git-count-objects.txt\n@@ -3,7 +3,7 @@ git-count-objects(1)\n \n NAME\n ----\n-git-count-objects - Reports on unpacked objects.\n+git-count-objects - Reports on unpacked objects\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-daemon.txt b/Documentation/git-daemon.txt\nindex 2cc6075..924a676 100644\n--- a/Documentation/git-daemon.txt\n+++ b/Documentation/git-daemon.txt\n@@ -3,7 +3,7 @@ git-daemon(1)\n \n NAME\n ----\n-git-daemon - A really simple server for git repositories.\n+git-daemon - A really simple server for git repositories\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-describe.txt b/Documentation/git-describe.txt\nindex 0efe82a..7a253ea 100644\n--- a/Documentation/git-describe.txt\n+++ b/Documentation/git-describe.txt\n@@ -3,7 +3,7 @@ git-describe(1)\n \n NAME\n ----\n-git-describe - Show the most recent tag that is reachable from a commit.\n+git-describe - Show the most recent tag that is reachable from a commit\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-diff-stages.txt b/Documentation/git-diff-stages.txt\nindex 28c60fc..3273918 100644\n--- a/Documentation/git-diff-stages.txt\n+++ b/Documentation/git-diff-stages.txt\n@@ -3,7 +3,7 @@ git-diff-stages(1)\n \n NAME\n ----\n-git-diff-stages - Compares content and mode of blobs between stages in an unmerged index file.\n+git-diff-stages - Compares content and mode of blobs between stages in an unmerged index file\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-diff.txt b/Documentation/git-diff.txt\nindex ca41634..890931c 100644\n--- a/Documentation/git-diff.txt\n+++ b/Documentation/git-diff.txt\n@@ -3,7 +3,7 @@ git-diff(1)\n \n NAME\n ----\n-git-diff - Show changes between commits, commit and working tree, etc.\n+git-diff - Show changes between commits, commit and working tree, etc\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-fetch-pack.txt b/Documentation/git-fetch-pack.txt\nindex 913b75b..bff9aa6 100644\n--- a/Documentation/git-fetch-pack.txt\n+++ b/Documentation/git-fetch-pack.txt\n@@ -3,7 +3,7 @@ git-fetch-pack(1)\n \n NAME\n ----\n-git-fetch-pack - Receive missing objects from another repository.\n+git-fetch-pack - Receive missing objects from another repository\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-fetch.txt b/Documentation/git-fetch.txt\nindex a67dc34..a9e86fd 100644\n--- a/Documentation/git-fetch.txt\n+++ b/Documentation/git-fetch.txt\n@@ -3,7 +3,7 @@ git-fetch(1)\n \n NAME\n ----\n-git-fetch - Download objects and a head from another repository.\n+git-fetch - Download objects and a head from another repository\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-format-patch.txt b/Documentation/git-format-patch.txt\nindex 9ac0636..7c467c5 100644\n--- a/Documentation/git-format-patch.txt\n+++ b/Documentation/git-format-patch.txt\n@@ -3,7 +3,7 @@ git-format-patch(1)\n \n NAME\n ----\n-git-format-patch - Prepare patches for e-mail submission.\n+git-format-patch - Prepare patches for e-mail submission\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-get-tar-commit-id.txt b/Documentation/git-get-tar-commit-id.txt\nindex 30b1fbf..48805b6 100644\n--- a/Documentation/git-get-tar-commit-id.txt\n+++ b/Documentation/git-get-tar-commit-id.txt\n@@ -3,7 +3,7 @@ git-get-tar-commit-id(1)\n \n NAME\n ----\n-git-get-tar-commit-id - Extract commit ID from an archive created using git-tar-tree.\n+git-get-tar-commit-id - Extract commit ID from an archive created using git-tar-tree\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-hash-object.txt b/Documentation/git-hash-object.txt\nindex 0924931..04e8d00 100644\n--- a/Documentation/git-hash-object.txt\n+++ b/Documentation/git-hash-object.txt\n@@ -3,7 +3,7 @@ git-hash-object(1)\n \n NAME\n ----\n-git-hash-object - Computes object ID and optionally creates a blob from a file.\n+git-hash-object - Computes object ID and optionally creates a blob from a file\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-http-push.txt b/Documentation/git-http-push.txt\nindex c7066d6..7e1f894 100644\n--- a/Documentation/git-http-push.txt\n+++ b/Documentation/git-http-push.txt\n@@ -3,7 +3,7 @@ git-http-push(1)\n \n NAME\n ----\n-git-http-push - Push missing objects using HTTP/DAV.\n+git-http-push - Push missing objects using HTTP/DAV\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-lost-found.txt b/Documentation/git-lost-found.txt\nindex 03156f2..f52a9d7 100644\n--- a/Documentation/git-lost-found.txt\n+++ b/Documentation/git-lost-found.txt\n@@ -3,7 +3,7 @@ git-lost-found(1)\n \n NAME\n ----\n-git-lost-found - Recover lost refs that luckily have not yet been pruned.\n+git-lost-found - Recover lost refs that luckily have not yet been pruned\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-ls-remote.txt b/Documentation/git-ls-remote.txt\nindex 66fe60f..ae4c1a2 100644\n--- a/Documentation/git-ls-remote.txt\n+++ b/Documentation/git-ls-remote.txt\n@@ -3,7 +3,7 @@ git-ls-remote(1)\n \n NAME\n ----\n-git-ls-remote - Look at references other repository has.\n+git-ls-remote - Look at references other repository has\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-ls-tree.txt b/Documentation/git-ls-tree.txt\nindex b92a8b2..5bf6d8b 100644\n--- a/Documentation/git-ls-tree.txt\n+++ b/Documentation/git-ls-tree.txt\n@@ -3,7 +3,7 @@ git-ls-tree(1)\n \n NAME\n ----\n-git-ls-tree - Lists the contents of a tree object.\n+git-ls-tree - Lists the contents of a tree object\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-mailinfo.txt b/Documentation/git-mailinfo.txt\nindex 8890754..ea0a065 100644\n--- a/Documentation/git-mailinfo.txt\n+++ b/Documentation/git-mailinfo.txt\n@@ -3,7 +3,7 @@ git-mailinfo(1)\n \n NAME\n ----\n-git-mailinfo - Extracts patch from a single e-mail message.\n+git-mailinfo - Extracts patch from a single e-mail message\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-mailsplit.txt b/Documentation/git-mailsplit.txt\nindex e0703e9..209e36b 100644\n--- a/Documentation/git-mailsplit.txt\n+++ b/Documentation/git-mailsplit.txt\n@@ -3,7 +3,7 @@ git-mailsplit(1)\n \n NAME\n ----\n-git-mailsplit - Totally braindamaged mbox splitter program.\n+git-mailsplit - Totally braindamaged mbox splitter program\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-mv.txt b/Documentation/git-mv.txt\nindex 21a8664..207c43a 100644\n--- a/Documentation/git-mv.txt\n+++ b/Documentation/git-mv.txt\n@@ -3,7 +3,7 @@ git-mv(1)\n \n NAME\n ----\n-git-mv - Move or rename a file, directory or symlink.\n+git-mv - Move or rename a file, directory or symlink\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-name-rev.txt b/Documentation/git-name-rev.txt\nindex e37b0b8..6870708 100644\n--- a/Documentation/git-name-rev.txt\n+++ b/Documentation/git-name-rev.txt\n@@ -3,7 +3,7 @@ git-name-rev(1)\n \n NAME\n ----\n-git-name-rev - Find symbolic names for given revs.\n+git-name-rev - Find symbolic names for given revs\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-pack-objects.txt b/Documentation/git-pack-objects.txt\nindex 567dabf..4991f88 100644\n--- a/Documentation/git-pack-objects.txt\n+++ b/Documentation/git-pack-objects.txt\n@@ -3,7 +3,7 @@ git-pack-objects(1)\n \n NAME\n ----\n-git-pack-objects - Create a packed archive of objects.\n+git-pack-objects - Create a packed archive of objects\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-pack-redundant.txt b/Documentation/git-pack-redundant.txt\nindex a81cb97..8fb0659 100644\n--- a/Documentation/git-pack-redundant.txt\n+++ b/Documentation/git-pack-redundant.txt\n@@ -3,7 +3,7 @@ git-pack-redundant(1)\n \n NAME\n ----\n-git-pack-redundant - Program used to find redundant pack files.\n+git-pack-redundant - Program used to find redundant pack files\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-patch-id.txt b/Documentation/git-patch-id.txt\nindex c8bd197..723b8cc 100644\n--- a/Documentation/git-patch-id.txt\n+++ b/Documentation/git-patch-id.txt\n@@ -3,7 +3,7 @@ git-patch-id(1)\n \n NAME\n ----\n-git-patch-id - Generate a patch ID.\n+git-patch-id - Generate a patch ID\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-peek-remote.txt b/Documentation/git-peek-remote.txt\nindex 915d3f8..a00060c 100644\n--- a/Documentation/git-peek-remote.txt\n+++ b/Documentation/git-peek-remote.txt\n@@ -3,7 +3,7 @@ git-peek-remote(1)\n \n NAME\n ----\n-git-peek-remote - Lists the references in a remote repository.\n+git-peek-remote - Lists the references in a remote repository\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt\nindex 20175f4..51577fc 100644\n--- a/Documentation/git-pull.txt\n+++ b/Documentation/git-pull.txt\n@@ -3,7 +3,7 @@ git-pull(1)\n \n NAME\n ----\n-git-pull - Pull and merge from another repository.\n+git-pull - Pull and merge from another repository\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-push.txt b/Documentation/git-push.txt\nindex 6f4a48a..d5b5ca1 100644\n--- a/Documentation/git-push.txt\n+++ b/Documentation/git-push.txt\n@@ -3,7 +3,7 @@ git-push(1)\n \n NAME\n ----\n-git-push - Update remote refs along with associated objects.\n+git-push - Update remote refs along with associated objects\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-rebase.txt b/Documentation/git-rebase.txt\nindex f037d12..4d5b546 100644\n--- a/Documentation/git-rebase.txt\n+++ b/Documentation/git-rebase.txt\n@@ -3,7 +3,7 @@ git-rebase(1)\n \n NAME\n ----\n-git-rebase - Rebase local commits to new upstream head.\n+git-rebase - Rebase local commits to new upstream head\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-relink.txt b/Documentation/git-relink.txt\nindex 6240535..aca6012 100644\n--- a/Documentation/git-relink.txt\n+++ b/Documentation/git-relink.txt\n@@ -3,7 +3,7 @@ git-relink(1)\n \n NAME\n ----\n-git-relink - Hardlink common objects in local repositories.\n+git-relink - Hardlink common objects in local repositories\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-repo-config.txt b/Documentation/git-repo-config.txt\nindex 00efde5..26759a8 100644\n--- a/Documentation/git-repo-config.txt\n+++ b/Documentation/git-repo-config.txt\n@@ -3,7 +3,7 @@ git-repo-config(1)\n \n NAME\n ----\n-git-repo-config - Get and set options in .git/config.\n+git-repo-config - Get and set options in .git/config\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-request-pull.txt b/Documentation/git-request-pull.txt\nindex 2463ec9..478a5fd 100644\n--- a/Documentation/git-request-pull.txt\n+++ b/Documentation/git-request-pull.txt\n@@ -3,7 +3,7 @@ git-request-pull(1)\n \n NAME\n ----\n-git-request-pull - Generates a summary of pending changes.\n+git-request-pull - Generates a summary of pending changes\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-reset.txt b/Documentation/git-reset.txt\nindex b4e737e..b7b9798 100644\n--- a/Documentation/git-reset.txt\n+++ b/Documentation/git-reset.txt\n@@ -3,7 +3,7 @@ git-reset(1)\n \n NAME\n ----\n-git-reset - Reset current HEAD to the specified state.\n+git-reset - Reset current HEAD to the specified state\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-rev-parse.txt b/Documentation/git-rev-parse.txt\nindex 29b5789..8b95df0 100644\n--- a/Documentation/git-rev-parse.txt\n+++ b/Documentation/git-rev-parse.txt\n@@ -3,7 +3,7 @@ git-rev-parse(1)\n \n NAME\n ----\n-git-rev-parse - Pick out and massage parameters.\n+git-rev-parse - Pick out and massage parameters\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-revert.txt b/Documentation/git-revert.txt\nindex e27c680..71f7815 100644\n--- a/Documentation/git-revert.txt\n+++ b/Documentation/git-revert.txt\n@@ -3,7 +3,7 @@ git-revert(1)\n \n NAME\n ----\n-git-revert - Revert an existing commit.\n+git-revert - Revert an existing commit\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-rm.txt b/Documentation/git-rm.txt\nindex d8a5afa..c9c3088 100644\n--- a/Documentation/git-rm.txt\n+++ b/Documentation/git-rm.txt\n@@ -3,7 +3,7 @@ git-rm(1)\n \n NAME\n ----\n-git-rm - Remove files from the working tree and from the index.\n+git-rm - Remove files from the working tree and from the index\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-send-pack.txt b/Documentation/git-send-pack.txt\nindex 577f06a..08e0705 100644\n--- a/Documentation/git-send-pack.txt\n+++ b/Documentation/git-send-pack.txt\n@@ -3,7 +3,7 @@ git-send-pack(1)\n \n NAME\n ----\n-git-send-pack - Push missing objects packed.\n+git-send-pack - Push missing objects packed\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-sh-setup.txt b/Documentation/git-sh-setup.txt\nindex 6ef59ac..6742c9b 100644\n--- a/Documentation/git-sh-setup.txt\n+++ b/Documentation/git-sh-setup.txt\n@@ -3,7 +3,7 @@ git-sh-setup(1)\n \n NAME\n ----\n-git-sh-setup - Common git shell script setup code.\n+git-sh-setup - Common git shell script setup code\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-shortlog.txt b/Documentation/git-shortlog.txt\nindex bf8db8b..54fb922 100644\n--- a/Documentation/git-shortlog.txt\n+++ b/Documentation/git-shortlog.txt\n@@ -3,7 +3,7 @@ git-shortlog(1)\n \n NAME\n ----\n-git-shortlog - Summarize 'git log' output.\n+git-shortlog - Summarize 'git log' output\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-show-branch.txt b/Documentation/git-show-branch.txt\nindex e474cd0..d3b6e62 100644\n--- a/Documentation/git-show-branch.txt\n+++ b/Documentation/git-show-branch.txt\n@@ -3,7 +3,7 @@ git-show-branch(1)\n \n NAME\n ----\n-git-show-branch - Show branches and their commits.\n+git-show-branch - Show branches and their commits\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-show.txt b/Documentation/git-show.txt\nindex 9c359a4..2b4df3f 100644\n--- a/Documentation/git-show.txt\n+++ b/Documentation/git-show.txt\n@@ -3,7 +3,7 @@ git-show(1)\n \n NAME\n ----\n-git-show - Show one commit with difference it introduces.\n+git-show - Show one commit with difference it introduces\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-status.txt b/Documentation/git-status.txt\nindex 753fc08..e446f48 100644\n--- a/Documentation/git-status.txt\n+++ b/Documentation/git-status.txt\n@@ -3,7 +3,7 @@ git-status(1)\n \n NAME\n ----\n-git-status - Show working tree status.\n+git-status - Show working tree status\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-stripspace.txt b/Documentation/git-stripspace.txt\nindex 528a1b6..3a03dd0 100644\n--- a/Documentation/git-stripspace.txt\n+++ b/Documentation/git-stripspace.txt\n@@ -3,7 +3,7 @@ git-stripspace(1)\n \n NAME\n ----\n-git-stripspace - Filter out empty lines.\n+git-stripspace - Filter out empty lines\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-unpack-objects.txt b/Documentation/git-unpack-objects.txt\nindex 31ea34d..1828062 100644\n--- a/Documentation/git-unpack-objects.txt\n+++ b/Documentation/git-unpack-objects.txt\n@@ -3,7 +3,7 @@ git-unpack-objects(1)\n \n NAME\n ----\n-git-unpack-objects - Unpack objects from a packed archive.\n+git-unpack-objects - Unpack objects from a packed archive\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-upload-pack.txt b/Documentation/git-upload-pack.txt\nindex 3d8f8ef..4795e98 100644\n--- a/Documentation/git-upload-pack.txt\n+++ b/Documentation/git-upload-pack.txt\n@@ -3,7 +3,7 @@ git-upload-pack(1)\n \n NAME\n ----\n-git-upload-pack - Send missing objects packed.\n+git-upload-pack - Send missing objects packed\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-verify-pack.txt b/Documentation/git-verify-pack.txt\nindex d032280..4962d69 100644\n--- a/Documentation/git-verify-pack.txt\n+++ b/Documentation/git-verify-pack.txt\n@@ -3,7 +3,7 @@ git-verify-pack(1)\n \n NAME\n ----\n-git-verify-pack - Validate packed git archive files.\n+git-verify-pack - Validate packed git archive files\n \n \n SYNOPSIS\ndiff --git a/Documentation/git-verify-tag.txt b/Documentation/git-verify-tag.txt\nindex b8a73c4..0f9bdb5 100644\n--- a/Documentation/git-verify-tag.txt\n+++ b/Documentation/git-verify-tag.txt\n@@ -3,7 +3,7 @@ git-verify-tag(1)\n \n NAME\n ----\n-git-verify-tag - Check the GPG signature of tag.\n+git-verify-tag - Check the GPG signature of tag\n \n SYNOPSIS\n --------\ndiff --git a/Documentation/git-whatchanged.txt b/Documentation/git-whatchanged.txt\nindex 6c150b0..f02f939 100644\n--- a/Documentation/git-whatchanged.txt\n+++ b/Documentation/git-whatchanged.txt\n@@ -3,7 +3,7 @@ git-whatchanged(1)\n \n NAME\n ----\n-git-whatchanged - Show logs with difference each commit introduces.\n+git-whatchanged - Show logs with difference each commit introduces\n \n \n SYNOPSIS\n"},{"id":"17385","messageId":"20060309171434.GD4297@lug-owl.de","threadId":"3612","inReplyTo":"20060309162419.GB4484@c165.ib.student.liu.se","subject":"Re: [PATCH 1/3] Nicer output from 'git'","fromName":"Jan-Benedict Glaw","fromEmail":"jbglaw@lug-owl.de","sentAt":"2006-03-09T17:14:34Z","receivedAt":"2006-03-09T17:14:34Z","isPatch":true,"sender":{"key":"jbglaw@lug-owl.de","avatar":null},"body":"On Thu, 2006-03-09 17:24:19 +0100, Fredrik Kuivinen <freku045@student.liu.se> wrote:\n> --- /dev/null\n> +++ b/generate-cmdlist.sh\n> @@ -0,0 +1,22 @@\n> +#!/bin/sh\n> +\n> +echo \"/* Automatically generated by $0 */\n> +struct cmdname_help \n> +{\n> +    char name[16];\n> +    char help[64];\n> +};\n> +\n> +struct cmdname_help common_cmds[] = {\"\n\nI'd use a here document for this.\n\n> +# Please keep this list sorted\n> +for i in \"add\" \"apply\" \"bisect\" \"branch\" \"checkout\" \"cherry-pick\" \"clone\" \\\n> +\"commit\" \"diff\" \"fetch\" \"grep\" \"init-db\" \"log\" \"merge\" \"mv\" \\\n> +\"prune\" \"pull\" \"push\" \"rebase\" \"reset\" \"revert\" \"rm\" \"show-branch\" \\\n> +\"status\" \"tag\" \"verify-tag\" \"whatchanged\"\n\nYou can omit all the quotes here--these words won't change by any\nmeans of variable substitution or whitespace rearrangement...\n\n> +static void list_common_cmds_help()\n> +{\n> +\tint i, longest = 0;\n> +\n> +\tfor(i = 0; i < sizeof(common_cmds)/sizeof(struct cmdname_help); i++) {\n\nThis smells like a good candidate for ARRAY_SIZE()?\n\n> +\t\tif(strlen(common_cmds[i].name) > longest)\n> +\t\t\tlongest = strlen(common_cmds[i].name);\n> +\t}\n\nMaybe make len a size_t instead of int?\n\n> +\tputs(\"The most commonly used git commands are:\");\n> +\tfor(i = 0; i < sizeof(common_cmds)/sizeof(struct cmdname_help); i++) {\n\nARRAY_SIZE()\n\nMfG, JBG\n\n-- \nJan-Benedict Glaw       jbglaw@lug-owl.de    . +49-172-7608481             _ O _\n\"Eine Freie Meinung in  einem Freien Kopf    | Gegen Zensur | Gegen Krieg  _ _ O\n für einen Freien Staat voll Freier Bürger\"  | im Internet! |   im Irak!   O O O\nret = do_actions((curr | FREE_SPEECH) & ~(NEW_COPYRIGHT_LAW | DRM | TCPA));\n"},{"id":"17388","messageId":"20060309173203.GA8578@mythryan2.michonline.com","threadId":"3612","inReplyTo":"20060309161722.GA4484@c165.ib.student.liu.se","subject":"Re: [PATCH 0/3] Make the output of 'git' nicer","fromName":"Ryan Anderson","fromEmail":"ryan@michonline.com","sentAt":"2006-03-09T17:32:04Z","receivedAt":"2006-03-09T17:32:04Z","isPatch":true,"sender":{"key":"ryan@michonline.com","avatar":null},"body":"On Thu, Mar 09, 2006 at 05:17:22PM +0100, Fredrik Kuivinen wrote:\n> Hi,\n> \n> This series makes the output of 'git' easier to read (IMHO). With this\n> patch the output will look like this:\n\nYou'll probably want to add \"show\" to that list.\n\n-- \n\nRyan Anderson\n  sometimes Pug Majere\n"}]}