You are not logged in.
While installing the (very nice) pianobar-git package today, I noticed that xxx-git pkgbuilds generally have a few lines like so:
if [ -d $startdir/src/$_gitname ] ; then
cd $_gitname && git pull origin
msg "The local files are updated."
else
git clone $_gitroot
fi
This is how it is in the example in the wiki.
Is it okay to use the --depth option of git-clone? As I commented on the AUR page,
You might consider using the --depth option for git-clone, since the vast majority of the users aren't going to be needing to view past history (and I think yaourt throws away the git repository, anyways). This'll speed up the clone, especially as the repository continues to grow.
Thoughts?
EDIT: Oh yes, and from the manpage for git-clone:
--depth <depth>
Create a shallow clone with a history truncated to the specified number of revisions. A shallow repository has a number of limitations (you cannot clone or fetch from it, nor push from nor into it), but is adequate if you are only interested in the recent history of a large project with a long history, and would want to send in fixes as patches.
Last edited by Xiong Chiamiov (2009-08-05 21:16:36)
Offline
Sounds reasonable. I have some -git-packages in AUR and will test how it works. Do you have a "sane default" for the <depth>?
Offline
From http://git.or.cz/gitwiki/GitFaq:
How do I use git for large projects, where the repository is large, say approaching 1 TB, but a checkout is only a few hundred MB? Will every developer need 1 TB of local disk space?
In general, git is not a viable solution for the the case of a large repository with relatively small individual checkouts. However, if developers do not intend to clone, fetch, push into or push from their repositories, then use shallow clones
git clone --depth 1 <url>
Last edited by NVS (2009-08-06 09:51:06)
Offline
I am using the shallow clone method for the "lilypond-git" package now, and it works quite well.
Offline