threads / discuss / 17426

Re: do you recommend "git" (over svn) for a 1-person team???

Subject: Re: do you recommend "git" (over svn) for a 1-person team???

## tl;dr

12 messages between Jan 29, 2009 and Jan 30, 2009.

replies: 11people: 9as markdown or json

Sverre Rabbelier· Jan 29, 2009, 01:38 UTC · re: Greg Hauptmann · lore
Heya,

On Thu, Jan 29, 2009 at 02:25, Greg Hauptmann <greg.hauptmann.ruby@gmail.com> wrote:

> Do you recommend "git" (over svn) for a 1-person team???   (the
> ability to commit whilst offline on my laptop sounds potentially
> enough reason)

Are you seriously asking if you should git instead of svn on the git mailing list, or am I missing something? :P.

Seriously though, yes, git works very nicely for 1-person teams as well as for large teams. Especially the ability to "git init && git add . && git commit -m 'got part of the assignment done'" has helped me a lot. Before I started using git I would come to the point where I thought 'ah, good, it almost works, now all I have to do is add feature x, and then 10 minutes later I'd be wishing I had used some form of revision control so I could go back to that working version!

</testemonial>
-- 
Cheers,

Sverre Rabbelier
Ted Pavlic· Jan 29, 2009, 02:09 UTC · re: Greg Hauptmann · lore
> Do you recommend "git" (over svn) for a 1-person team???   (the
> ability to commit whilst offline on my laptop sounds potentially
> enough reason)

At this point, it is clear that you've bought into using *some* form of revision control locally. So you are really asking whether DVCS is appropriate for personal-only use. If all you care about is the ability to commit locally, then you might as well use vanilla RCS (i.e., the ultimate "plumbing" behind SVN).

How easy DVCS solutions make merging and rebasing is a secondary feature for me. Primarily, I like that while doing my work, I don't ever have to *think* about the revision control. I don't have to check out or lock files. I don't have to worry about checking in all of my changes. I just work, and, when I'm ready, the DVCS takes care of everything else. It's the *overall* ease of use that makes DVCS so valuable to me... (and who knows... maybe later someone will want to clone my repo and we'll trade commits back and forth)

[ Keep in mind that git is not the only DVCS. For some of my personal projects, I use hg (Mercurial), and for others I use git. On none of them do I use SVN. Unfortunately, the proliferation of SVN on SourceForge has prevented me from contributed myriad local patches to projects that are otherwise very important to me. Perhaps another great reason to use DVCS locally is that you'll be putting implicit pressure on places like SF to modernize. ]

Best -- Ted

-- 
Ted Pavlic <ted@tedpavlic.com>

   Please visit my ALS association page:
         http://web.alsa.org/goto/tedpavlic
   My family appreciates your support in the fight to defeat ALS.
Martin Langhoff· Jan 29, 2009, 02:28 UTC · re: James Pickens · lore
On Thu, Jan 29, 2009 at 3:15 PM, James Pickens <jepicken@gmail.com> wrote:
> Greg Hauptmann <greg.hauptmann.ruby@gmail.com> wrote:
>> Do you recommend "git" (over svn) for a 1-person team???
>
> Yes, emphatically.  I do it myself all the time.
+1!
 - offline work on your laptop
 - "git stash"
 - keep various branches (experimental, feature, stable...), with
untold flexibility for cherrypicking, merges, etc
 - bisect!
 - visualise things with gitk
 - search with gitk for specific bits of code, changes (pickaxe), etc
once you start... it's a bit addictive...
m
-- 
 martin.langhoff@gmail.com
 martin@laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
Greg Hauptmann· Jan 29, 2009, 02:46 UTC · re: Martin Langhoff · lore

does the concept of me setting up my own central git server as well make any sense from the point of view of a way to ensure I can (when I'm not remote) "check-in" to the central git server & thereby keep a separate copy of my code (i.e. effectively a backup)

2009/1/29 Martin Langhoff <martin.langhoff@gmail.com>:
Show 27 quoted lines
> On Thu, Jan 29, 2009 at 3:15 PM, James Pickens <jepicken@gmail.com> wrote:
>> Greg Hauptmann <greg.hauptmann.ruby@gmail.com> wrote:
>>> Do you recommend "git" (over svn) for a 1-person team???
>>
>> Yes, emphatically.  I do it myself all the time.
>
> +1!
>
>  - offline work on your laptop
>  - "git stash"
>  - keep various branches (experimental, feature, stable...), with
> untold flexibility for cherrypicking, merges, etc
>  - bisect!
>  - visualise things with gitk
>  - search with gitk for specific bits of code, changes (pickaxe), etc
>
> once you start... it's a bit addictive...
>
>
> m
> --
>  martin.langhoff@gmail.com
>  martin@laptop.org -- School Server Architect
>  - ask interesting questions
>  - don't get distracted with shiny stuff  - working code first
>  - http://wiki.laptop.org/go/User:Martinlanghoff
>
-- 
Greg
http://blog.gregnet.org/
Ted Pavlic· Jan 29, 2009, 03:31 UTC · re: Greg Hauptmann · lore
> does the concept of me setting up my own central git server as well
> make any sense from the point of view of a way to ensure I can (when
> I'm not remote) "check-in" to the central git server&  thereby keep a
> separate copy of my code (i.e. effectively a backup)

You can always keep local clones that serve as "stable" backup repos. However, I think most people would suggest you just create stable/experimental branches and merge from one to the other as appropriate.

If you need some nice working examples of people using git for personal projects, I recommend you search Google for the many ways of using git to manage home directories. Applying git to home directory management involves many of the same questions (and answers) as what you're bringing up here, and it probably will give you some ideas about the most effective git usage for your case.

--Ted
-- 
Ted Pavlic <ted@tedpavlic.com>

   Please visit my ALS association page:
         http://web.alsa.org/goto/tedpavlic
   My family appreciates your support in the fight to defeat ALS.
Jeff King· Jan 29, 2009, 04:05 UTC · re: Greg Hauptmann · lore
On Thu, Jan 29, 2009 at 12:46:56PM +1000, Greg Hauptmann wrote:
> does the concept of me setting up my own central git server as well
> make any sense from the point of view of a way to ensure I can (when
> I'm not remote) "check-in" to the central git server & thereby keep a
> separate copy of my code (i.e. effectively a backup)
Yes, that is exactly what I do, because:
  - my central server is backed up, but my workstations are not
  - my central server is accessible remotely, but my workstations are
    not. So that is how I get code from one box to the other.
-Peff
Ted Pavlic· Jan 29, 2009, 03:27 UTC · re: Martin Langhoff · lore
>   - "git stash"

Not to mention StGit, which can achieve many of the same things as "git stash" while also letting you toy with your changeset history (which is definitely permissible on personal repos).

>   - visualise things with gitk
>   - search with gitk for specific bits of code, changes (pickaxe), etc

Not to mention tig, the wonderful ncurses (i.e., Terminal-based) tool recently announced on this mailing list.

(and "git grep", of course)
--Ted
-- 
Ted Pavlic <ted@tedpavlic.com>

   Please visit my ALS association page:
         http://web.alsa.org/goto/tedpavlic
   My family appreciates your support in the fight to defeat ALS.
Garry Dolley· Jan 29, 2009, 02:21 UTC · re: Greg Hauptmann · lore
On Thu, Jan 29, 2009 at 11:25:56AM +1000, Greg Hauptmann wrote:
Show 5 quoted lines
> Hi,
> 
> Do you recommend "git" (over svn) for a 1-person team???   (the
> ability to commit whilst offline on my laptop sounds potentially
> enough reason)

Absolutely. I have several repos on my filesystem and also a server that are for myself only.

-- 
Garry Dolley
ARP Networks, Inc.                          http://www.arpnetworks.com
Data center, VPS, and IP transit solutions  (818) 206-0181
Member Los Angeles County REACT, Unit 336   WQGK336
Blog                                        http://scie.nti.st
david@lang.hm· Jan 29, 2009, 02:57 UTC · re: Greg Hauptmann · lore
On Thu, 29 Jan 2009, Greg Hauptmann wrote:
Show 5 quoted lines
> Hi,
>
> Do you recommend "git" (over svn) for a 1-person team???   (the
> ability to commit whilst offline on my laptop sounds potentially
> enough reason)
well, if you use svn just put the svn repository on your laptop.

but if you use multiple systems you aren't really a 1-person team, you just happen to be one person working in different places.

also the distributed nature of git will make doing (and maintaining) backups easier, as well as recovering from the inevitable cases where you do development seperatly on your different machines and then need to combine them.

David Lang
Jakub Narebski· Jan 30, 2009, 12:46 UTC · re: Greg Hauptmann · lore
Greg Hauptmann <greg.hauptmann.ruby@gmail.com> writes:
> Do you recommend "git" (over svn) for a 1-person team???   (the
> ability to commit while offline on my laptop sounds potentially
> enough reason)
Beside much easier (I think) sync between desktop and offline laptop?

You don't need to setup Subversion server (even if it is setting up place for repositories): "git init" is enough (and you can use filesystem, or bundles, or ssh for sync).

You don't have '.svn' in each directory, but one '.git' at the top directory of your project (module).

You have (from what I have read) better support for file renames, better support for binary files, and much easier merging branches (before Subversion 1.5 you had to use third party tools (SVK or svnmerge) to not have to do merges "manually", and even now the support for easy merging is IMHO worse in SVN).

You have all those nifty tools like git-bisect, git-log with --grep and -S (pickaxe), git-mergetool, git-blame which follows code movement at request (see e.g. "git gui blame"), git-stash, incremental comitting, comitting part of changes, etc.

What Subversion has over Git (becuase it is longer) is better tools...
-- 
Jakub Narebski
Poland
ShadeHawk on #git

← back to recent threads