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

Re: Git vs svn. Is ... possible ?

From
Bill Lear <rael@zopyra.com>
Date
Mar 28, 2008, 14:09 UTC
Message-ID
<18412.64512.269165.652979@lisa.zopyra.com>
In-Reply-To
<20080328132438.GA32646@blackspire>
On Friday, March 28, 2008 at 14:24:38 (+0100) =?utf-8?B?UmFmYcWCIE11xbx5xYJv?= writes:
>Well, the actual question is:
>In svn I can do a remote diff (diff between two remote revisions) without
>having to do a checkout, is this possible for git ?

I'm not sure what you mean by "two remote revisions". Do you mean you are on machine X, and you want to diff content on machine Y and machine Z? If so, you could probably do that in git fairly easily with some script magic that would fetch the remote branches into local tracking branches, and then diff them. This would not literally require you to perform a "checkout", but you would need a git repo (actually a script could take care of creating a temporary repo, fetch into it, do the diff and then remove the temporary repo when done).

If you are talking about having an existing repo on machine X and diffing content that is on machine Y, you can do a fetch followed by a diff, so in that case you can do it literally "without having to do a checkout". Example: if you are working on master and want to see what is different between what you have and what is in a remote repo you are tracking, you can do "git fetch" then "git diff origin/master".

Bill
Previous: Theodore TsoNext: John Goerzen
Message 4 of 5 in “Git vs svn. Is ... possible ?”
  1. Rafał MużyłoMar 28, 2008
  2. Adam PiatyszekMar 28, 2008
  3. Theodore TsoMar 28, 2008
  4. Bill LearMar 28, 2008
  5. John GoerzenMar 31, 2008

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.