On Mon, 26 Mar 2012 23:56:58 -0700, jidanni@jidanni.org wrote:
Gentlemen, I am very thankful for http://www.mediawiki.org/wiki/Download_from_Git however it assumes one wants to 'get involved' with MediaWiki, whereas all I want to do is 'rsync snapshots' of the same files 'that the tarballs contain'. I.e., I just want to oh, every few days update (overwrite in place) my running copy of MediaWiki. No need for the history etc. that a 'clone' pulls in, or further 'pull's refresh. (The disk size I use should not grow a single bit between updates unless you upstream added some lines to a file.)
So it would be nice if someone mentioned the commands necessary so I can add them to that article. Let's pretend we are starting fresh (and not from SVN like in http://lists.wikimedia.org/pipermail/wikitech-l/2012-February/058190.html .)
99M git.git # A --bare clone 167M git-clean # A simple clone of master 215M git-fetch # A clone with a full fetch of the history of all branches 68M git-linked # A clone linked to git-clean 128M git-shallow # A --depth=5 clone 147M svn # A SVN checkout
Your concerns about space aren't really warranted. For something that keeps the entire source history it is very efficient at storing that history. A basic checkout (git-clean) is only 20MB more than a svn checkout.
To top it off git supports bare repos (repos with only history and no working copy) and linking a repo to another. ie: If you `git clone /abs/path/to/other/git/repo newrepo` git will use some hard links and references to the other repo instead of physically copying the data. By the way 99M (git.git) + 68M (git-linked) = 167M (git-clean), a --bare repo plus a linked repo is the same size as a normal clone.
And it gets even better if you have multiple wikis. If you have a setup like this: web/core.git web/somewiki.com/ web/anotherwiki.com/ Where core.git is a --bare repo and the other two are clones pointing to core.git, you will actually be SAVING space with git. In git that's 99M + 68M * 2 = 235M In svn that's 147M * 2 = 294M ;) Just two wikis and git is already taking less space than svn. And it goes in git's favor the more wikis you have: 1 = (git: 167M, svn: 147M; diff: -20M | 113.605442177%) 2 = (git: 235M, svn: 294M; diff: 59M | 79.9319727891%) 5 = (git: 439M, svn: 735M; diff: 296M | 59.7278911565%) 10 = (git: 779M, svn: 1470M; diff: 691M | 52.9931972789%) 50 = (git: 3499M, svn: 7350M; diff: 3851M | 47.6054421769%) 100 = (git: 6899M, svn: 14700M; diff: 7801M | 46.9319727891%) 500 = (git: 34099M, svn: 73500M; diff: 39401M | 46.3931972789%)