git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Newbie:  Do I need to download the entire repo to work on just 1 file?
@ 2009-03-22 22:08 Anthony Rasmussen
  2009-03-22 23:00 ` Sverre Rabbelier
  0 siblings, 1 reply; 8+ messages in thread
From: Anthony Rasmussen @ 2009-03-22 22:08 UTC (permalink / raw)
  To: git



Hi all,

The large website has a developers-only version of the site published on a server, which is tracked by git.

I
only have to work on 1 file.  I'd like to work on it, test changes on
the dev site, work on it some more, then commit when ready.

Do I have to download the entire rep onto my laptop in order to do this?  I have read and read, but I am quite confused :)

Thanks for your help!

_________________________________________________________________
Get quick access to your favorite MSN content with Internet Explorer 8. 
http://ie8.msn.com/microsoft/internet-explorer-8/en-us/ie8.aspx?ocid=B037MSN55C0701A

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Newbie: Do I need to download the entire repo to work on just 1  file?
  2009-03-22 22:08 Newbie: Do I need to download the entire repo to work on just 1 file? Anthony Rasmussen
@ 2009-03-22 23:00 ` Sverre Rabbelier
  2009-03-22 23:06   ` Geoffrey Lee
  2009-03-22 23:10   ` Nicolas Sebrecht
  0 siblings, 2 replies; 8+ messages in thread
From: Sverre Rabbelier @ 2009-03-22 23:00 UTC (permalink / raw)
  To: Anthony Rasmussen; +Cc: git

Heya,

On Sun, Mar 22, 2009 at 23:08, Anthony Rasmussen <evoluenta@hotmail.com> wrote:
> Do I have to download the entire rep onto my laptop in order to do this?  I have read and read, but I am quite confused :)

Yes, you do, in general though, git repositories are quite compact
compared to, say, a svn checkouts. It is not unheard of that the full
git clone is smaller than the same code as svn checkout.

-- 
Cheers,

Sverre Rabbelier

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Newbie: Do I need to download the entire repo to work on just 1  file?
  2009-03-22 23:00 ` Sverre Rabbelier
@ 2009-03-22 23:06   ` Geoffrey Lee
  2009-03-22 23:10   ` Nicolas Sebrecht
  1 sibling, 0 replies; 8+ messages in thread
From: Geoffrey Lee @ 2009-03-22 23:06 UTC (permalink / raw)
  To: git

On Sun, Mar 22, 2009 at 4:00 PM, Sverre Rabbelier <srabbelier@gmail.com> wrote:
> On Sun, Mar 22, 2009 at 23:08, Anthony Rasmussen <evoluenta@hotmail.com> wrote:
>> Do I have to download the entire rep onto my laptop in order to do this?  I have read and read, but I am quite confused :)
>
> Yes, you do, in general though, git repositories are quite compact
> compared to, say, a svn checkouts. It is not unheard of that the full
> git clone is smaller than the same code as svn checkout.

It depends on what you mean by "entire repo". Of course you need all
the source files to compile, but you do not need past revisions. Take
a look at the --depth parameter for git-clone.

-Geoffrey Lee

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Newbie: Do I need to download the entire repo to work on just 1 file?
  2009-03-22 23:00 ` Sverre Rabbelier
  2009-03-22 23:06   ` Geoffrey Lee
@ 2009-03-22 23:10   ` Nicolas Sebrecht
  2009-03-22 23:10     ` Sverre Rabbelier
  1 sibling, 1 reply; 8+ messages in thread
From: Nicolas Sebrecht @ 2009-03-22 23:10 UTC (permalink / raw)
  To: Sverre Rabbelier; +Cc: git


On Mon, Mar 23, 2009 at 12:00:59AM +0100, Sverre Rabbelier wrote:
> 
> Heya,
> 
> On Sun, Mar 22, 2009 at 23:08, Anthony Rasmussen <evoluenta@hotmail.com> wrote:
> > Do I have to download the entire rep onto my laptop in order to do this?  I have read and read, but I am quite confused :)

Please, wrap your lines to something convenient (72-80 characters max).

> Yes, you do

No, you don't. Why not use the '--depth <depth>' option of 'git clone' ?

-- 
Nicolas Sebrecht

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Newbie: Do I need to download the entire repo to work on just 1  file?
  2009-03-22 23:10   ` Nicolas Sebrecht
@ 2009-03-22 23:10     ` Sverre Rabbelier
  2009-03-22 23:16       ` Geoffrey Lee
  2009-03-22 23:31       ` Nicolas Sebrecht
  0 siblings, 2 replies; 8+ messages in thread
From: Sverre Rabbelier @ 2009-03-22 23:10 UTC (permalink / raw)
  To: Nicolas Sebrecht; +Cc: git

Heya,

On Mon, Mar 23, 2009 at 00:10, Nicolas Sebrecht
<nicolas.s-dev@laposte.net> wrote:
> No, you don't. Why not use the '--depth <depth>' option of 'git clone' ?

That depends on if he wants to push back to the original repo or not, right?

-- 
Cheers,

Sverre Rabbelier

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Newbie: Do I need to download the entire repo to work on just 1  file?
  2009-03-22 23:10     ` Sverre Rabbelier
@ 2009-03-22 23:16       ` Geoffrey Lee
  2009-03-22 23:31       ` Nicolas Sebrecht
  1 sibling, 0 replies; 8+ messages in thread
From: Geoffrey Lee @ 2009-03-22 23:16 UTC (permalink / raw)
  To: Sverre Rabbelier; +Cc: Nicolas Sebrecht, git

On Sun, Mar 22, 2009 at 4:10 PM, Sverre Rabbelier <srabbelier@gmail.com> wrote:
> That depends on if he wants to push back to the original repo or not, right?

Correct. You cannot push, fetch, or clone a shallow repo. And for Git
development, it's all about sending patches, so you don't need past
revisions.

-Geoffrey Lee

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Newbie: Do I need to download the entire repo to work on just 1 file?
  2009-03-22 23:10     ` Sverre Rabbelier
  2009-03-22 23:16       ` Geoffrey Lee
@ 2009-03-22 23:31       ` Nicolas Sebrecht
  2009-03-22 23:36         ` Nicolas Sebrecht
  1 sibling, 1 reply; 8+ messages in thread
From: Nicolas Sebrecht @ 2009-03-22 23:31 UTC (permalink / raw)
  To: Sverre Rabbelier; +Cc: Nicolas Sebrecht, git, Anthony Rasmussen


On Mon, Mar 23, 2009 at 12:10:48AM +0100, Sverre Rabbelier wrote:
> 
> Heya,
> 
> On Mon, Mar 23, 2009 at 00:10, Nicolas Sebrecht
> <nicolas.s-dev@laposte.net> wrote:
> > No, you don't. Why not use the '--depth <depth>' option of 'git clone' ?
> 
> That depends on if he wants to push back to the original repo or not, right?

It depends of what the OP means by "entire repository". You can't
"cherry-pick" one single file without download the entire tree of the
working directory.

You can push with a truncated history. What you can't do is checkout
from the history you don't have in your local repository.

-- 
Nicolas Sebrecht

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Newbie: Do I need to download the entire repo to work on just 1 file?
  2009-03-22 23:31       ` Nicolas Sebrecht
@ 2009-03-22 23:36         ` Nicolas Sebrecht
  0 siblings, 0 replies; 8+ messages in thread
From: Nicolas Sebrecht @ 2009-03-22 23:36 UTC (permalink / raw)
  To: Nicolas Sebrecht; +Cc: Sverre Rabbelier, git, Anthony Rasmussen


On Mon, Mar 23, 2009 at 12:31:20AM +0100, Nicolas Sebrecht wrote:

> You can push with a truncated history. What you can't do is checkout
> from the history you don't have in your local repository.

I just told my biggest mistake today. It's time to go to the bed.

-- 
Nicolas Sebrecht

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2009-03-22 23:37 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-22 22:08 Newbie: Do I need to download the entire repo to work on just 1 file? Anthony Rasmussen
2009-03-22 23:00 ` Sverre Rabbelier
2009-03-22 23:06   ` Geoffrey Lee
2009-03-22 23:10   ` Nicolas Sebrecht
2009-03-22 23:10     ` Sverre Rabbelier
2009-03-22 23:16       ` Geoffrey Lee
2009-03-22 23:31       ` Nicolas Sebrecht
2009-03-22 23:36         ` Nicolas Sebrecht

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).