Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
oxplot
· 11y ago · 0 comments
That only gives you the commit for the head of the branches. If there were multiple commits since you checked last, you'll miss some!
Comments
[–]
fenollp
11y ago
You will miss some. But then you just make a diff on the commits' SHA and only then you clone the repo (or fetch an archive, which is quicker).
You save a lot of time / bandwidth / space this way.
[–]
oxplot
OP
11y ago
You only
delay
saving time and bandwidth — you eventually have to clone the repo for any ops other than checking the head SHAs and unless the repo is rarely updated, the delay will be short.
[–]
fenollp
11y ago
Use git-archive or curl: gzipped source code is always smaller than a full versioned repo…
[–]
oxplot
OP
11y ago
You don't need the full versioned repo, just the top commit (ie cloning with depth=1). Also, git compresses the objects before sending them.