git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: just fetching HEAD of repository

From
Jakub Narebski <jnareb@gmail.com>
Date
May 25, 2007, 10:56 UTC
Message-ID
<f36f3t$teg$1@sea.gmane.org>
In-Reply-To
<566574ef0705210201wc5c0adbmaa22d197b16bf72d@mail.gmail.com>
Stian Haklev wrote:
Show 8 quoted lines
> After checking all the docs, I am still wondering if there is a way to
> get only the last commit from a given git repository. Sometimes I
> really just want the latest code so I can compile it - and let's say
> they are not running gitweb, or it is not convenient to go to gitweb
> and ask for a tar package to be made? This is especially relevant in
> countries with slow internet connection - here in Indonesia it takes
> me an hour to clone the git repository for example, never mind let's
> say the Linux kernel.
Depending on what you want, try either:
  $ git clone --depth=1 <repository URL>
or
  $ git archive --remote=<repository URL> HEAD
(if the remote side supports it)
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
Previous: Guilhem Bonnefille
Message 4 of 4 in “just fetching HEAD of repository”
  1. Stian HaklevMay 21, 2007
  2. Matthieu MoyMay 21, 2007
  3. Guilhem BonnefilleMay 23, 2007
  4. Jakub NarebskiMay 25, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.