{"thread":{"id":"11371","subject":"[PATCH] everyday: replace 'repack' with 'gc'","startedAt":"2007-12-20T14:05:45Z","lastAt":"2007-12-20T14:05:46Z","messageCount":2,"participants":["Miklos Vajna"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"63866","messageId":"1198159546-11368-1-git-send-email-vmiklos@frugalware.org","threadId":"11371","inReplyTo":"20071219225618.GA7378@genesis.frugalware.org","subject":"[PATCH] everyday: replace 'prune' with 'gc --prune'","fromName":"Miklos Vajna","fromEmail":"vmiklos@frugalware.org","sentAt":"2007-12-20T14:05:45Z","receivedAt":"2007-12-20T14:05:45Z","isPatch":true,"sender":{"key":"vmiklos@frugalware.org","avatar":"https://gravatar.com/avatar/401c1cbbb3a5d13e650c691a2c71d6fd0b80df1a01bc74d9f1972675dd58f2bd?d=mp&s=160"},"body":"This document is for newcomers, so it's good to mention gc for housekeeping\ntasks instead of running prune manually.\n\nSigned-off-by: Miklos Vajna <vmiklos@frugalware.org>\n---\n Documentation/everyday.txt |    8 +++-----\n 1 files changed, 3 insertions(+), 5 deletions(-)\n\ndiff --git a/Documentation/everyday.txt b/Documentation/everyday.txt\nindex ce7c170..a09c1d9 100644\n--- a/Documentation/everyday.txt\n+++ b/Documentation/everyday.txt\n@@ -30,8 +30,6 @@ Everybody uses these commands to maintain git repositories.\n \n   * gitlink:git-fsck[1] to check the repository for errors.\n \n-  * gitlink:git-prune[1] to remove unused objects in the repository.\n-\n   * gitlink:git-repack[1] to pack loose objects for efficiency.\n \n   * gitlink:git-gc[1] to do common housekeeping tasks such as\n@@ -56,13 +54,13 @@ disk space is wasted by not repacking.\n <3> without `-a` repacks incrementally.  repacking every 4-5MB\n of loose objects accumulation may be a good rule of thumb.\n <4> it is easier to use `git gc` than individual housekeeping commands\n-such as `prune` and `repack`.  This runs `repack -a -d`.\n+such as `prune` and `repack`.\n \n Repack a small project into single pack.::\n +\n ------------\n $ git repack -a -d <1>\n-$ git prune\n+$ git gc --prune\n ------------\n +\n <1> pack all the objects reachable from the refs into one pack,\n@@ -189,7 +187,7 @@ $ git pull <3>\n $ git log -p ORIG_HEAD.. arch/i386 include/asm-i386 <4>\n $ git pull git://git.kernel.org/pub/.../jgarzik/libata-dev.git ALL <5>\n $ git reset --hard ORIG_HEAD <6>\n-$ git prune <7>\n+$ git gc --prune <7>\n $ git fetch --tags <8>\n ------------\n +\n-- \n1.5.4.rc0.67.gf9c5-dirty\n"},{"id":"63865","messageId":"1198159546-11368-2-git-send-email-vmiklos@frugalware.org","threadId":"11371","inReplyTo":"1198159546-11368-1-git-send-email-vmiklos@frugalware.org","subject":"[PATCH] everyday: replace 'repack' with 'gc'","fromName":"Miklos Vajna","fromEmail":"vmiklos@frugalware.org","sentAt":"2007-12-20T14:05:46Z","receivedAt":"2007-12-20T14:05:46Z","isPatch":true,"sender":{"key":"vmiklos@frugalware.org","avatar":"https://gravatar.com/avatar/401c1cbbb3a5d13e650c691a2c71d6fd0b80df1a01bc74d9f1972675dd58f2bd?d=mp&s=160"},"body":"Most users don't want to run git repack manually, so suggest using gc instead.\n\nSigned-off-by: Miklos Vajna <vmiklos@frugalware.org>\n---\n Documentation/everyday.txt |   13 ++++---------\n 1 files changed, 4 insertions(+), 9 deletions(-)\n\ndiff --git a/Documentation/everyday.txt b/Documentation/everyday.txt\nindex a09c1d9..f1993e2 100644\n--- a/Documentation/everyday.txt\n+++ b/Documentation/everyday.txt\n@@ -30,8 +30,6 @@ Everybody uses these commands to maintain git repositories.\n \n   * gitlink:git-fsck[1] to check the repository for errors.\n \n-  * gitlink:git-repack[1] to pack loose objects for efficiency.\n-\n   * gitlink:git-gc[1] to do common housekeeping tasks such as\n     repack and prune.\n \n@@ -43,23 +41,20 @@ Check health and remove cruft.::\n ------------\n $ git fsck <1>\n $ git count-objects <2>\n-$ git repack <3>\n-$ git gc <4>\n+$ git gc <3>\n ------------\n +\n <1> running without `\\--full` is usually cheap and assures the\n repository health reasonably well.\n <2> check how many loose objects there are and how much\n disk space is wasted by not repacking.\n-<3> without `-a` repacks incrementally.  repacking every 4-5MB\n-of loose objects accumulation may be a good rule of thumb.\n-<4> it is easier to use `git gc` than individual housekeeping commands\n-such as `prune` and `repack`.\n+<3> repacks the local repository and performs other housekeeping tasks. Running\n+without `--prune` is a safe operation even while other ones are in progress.\n \n Repack a small project into single pack.::\n +\n ------------\n-$ git repack -a -d <1>\n+$ git gc <1>\n $ git gc --prune\n ------------\n +\n-- \n1.5.4.rc0.67.gf9c5-dirty\n"}]}