Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
sonic bed head
Dec 18, 2003

this is naturual, baby!
I am making this megathread because I often have questions with no answers rather than me having all the answers myself, but here are some resources.

SVN Red-Bean book - complete book on all of SVN functionality. A must read for anyone that uses SVN on a regular basis. It has helped me immensely once I got the idea of merging.

A tour of Git - basically a rundown of the useful commands.

Mercurial: The Definitive Guide - Recommended by Bonus

If anyone has any other link suggestions, let me know.

On to my question...

I have one trunk directory and used svn copy to make a branch. I've changed some things in the trunk including deleting some files. I've used svn log to figure out when the branch was made and what revisions I need to merge and proceeded to try to merge the changes from trunk into the branch. Everything merges correctly except the deletes. The svn merge command just says "skipped" next to all of the files that should have been deleted but all of the other changes are merged perfectly. I thought that skipped usually meant that a change was made to a file that doesn't exist in the working copy, but the file is definitely there (in repository as well as working copy) so I don't know what's wrong.

MonkeyMaker posted:

Didn't see this posted on the last page or so. Pro Git, new book, available for free online: http://progit.org/book/

sonic bed head fucked around with this message at 04:08 on Aug 4, 2009

Adbot
ADBOT LOVES YOU

hey mom its 420
May 12, 2007

There's also a very good book on Mercurial by Bryan O'Sullivan, worth czeching out.

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


I wanted to post this and see if anyone has any thoughts on how wrong our team is regarding CM. I know we're not right, I just don't know how wrong. (wall of text notice)

---

Some background: our team uses clearcase for version control, dictated by higher management. Not one of us has any real-world experience with it, and getting someone with said isn't in the cards, so me and one other guy have been winging it with the scant training available for this dozen-person team. Not a good start, I know. :(

What we do right now is this: we reserve /main/ to hold file versions for milestone releases--1.0, 2.0, whatever goes into the wild. We don't support or code for old releases, mind; we're keeping them only because management wants history. Whatever. Anyway, what we settled on was making, off of /main/, one branch per minor release (so /main/bld1.0/, /main/bld1.1/, etc). Branched off THOSE are minor releases, and finally, branched off those are development branches. So one developer might be coding in /main/bld1.0/bld1.0.4/req22/, another might be in /main/bld1.0/bld1.0.3/bug3221/, or something.

A typical development area config spec would look like this, to take the last example:

code:
element * CHECKEDOUT
element * .../bug3221/LATEST
element * BUILD_1.0.3 -mkbranch bug3221
BUILD_1.0.3 is a label me and the other CM guy assign to all versions of all files when a successful build is done, so developer's work areas stay stable. These build labels never change once assigned.

When a developer has something to move into the release being worked on, he first updates his config spec so instead of taking from BUILD_X.X.X, it takes from BUILD_LATEST, which we CM guys keep updated to match the most recent build. Then the developer performs a findmerge from BUILD_LATEST into his work branch, updating it with all the changes that have taken place to files he's touched in his baseline since he started development (files he HASN'T touched are taken care of by the config spec change). He performs the merge in his branch, tests it, and passes notice to CM that it's ready, and we insert that branch into the baseline after our own testing. (We have the developer update his code to match latest instead of doing it ourselves because, frankly, we have our own development to do, and CM would turn into, well, the full-time job it bloody well should be if we had to do the reconciling ourselves.)

---

That got a little long winded, sorry--don't know how much detail is too much detail, like I said I have no idea what the hell I'm doing. But are my partner and I at least on something like the right track? It's worked for the past month or two this way, but without having done this before I have no basis for comparison.

mwarkentin
Oct 26, 2004
OP, did you use the "svn delete" command to delete the files, or did you remove them manually?

sonic bed head
Dec 18, 2003

this is naturual, baby!

mwarkentin posted:

OP, did you use the "svn delete" command to delete the files, or did you remove them manually?

I used "svn delete." The files are definitely not in the head revision of the trunk. Also, the merge command is exactly skipping the ones that have been deleted, so it must know that the deletions have happened.

TOO SCSI FOR MY CAT
Oct 12, 2008

this is what happens when you take UI design away from engineers and give it to a bunch of hipster art student "designers"
Bazaar has some very nice documentation, much of which is useful with other (D)VCS as well. Bazaar in five minutes and the user guide are worth a look.

Also, considering how large IBM is, I'm always surprised at how terrible their VCS tools (ClearCase and Continuus) are.

Pesch
Nov 4, 2006
Wholly Chao
Here's something I've been wondering: How do you mirror an SVN server? If I want a working SVN repository on my Desktop and a mirror on a remote server, how would I go about doing that?

Slurps Mad Rips
Jan 25, 2009

Bwaltow!

Git for the Lazy

I found it to be a very easy to understand tutorial that gets you through the basics pretty fast, which is great for people who are just getting into the whole content management thing.

Also check out Redmine Despite it using Ruby on Rails, it has a great bug tracker and it integrates with git which is totally bitchin'

Pardot
Jul 25, 2001




GitReady is great for looking up specific tasks, and github is the best source hosting site ever.

Begby
Apr 7, 2005

Light saber? Check. Black boots? Check. Codpiece? Check. He's more machine than kid now.

Pesch posted:

Here's something I've been wondering: How do you mirror an SVN server? If I want a working SVN repository on my Desktop and a mirror on a remote server, how would I go about doing that?

Out of curiosity would you want the actual repository on your desktop?

There is a tool though called svnsync that will mirror it to a readonly copy. You can't commit changes to the mirror and then have it sync to the master though.

You can also use the 'svnadmin hotcopy' command if all you are going for is a copy of the repository.

ashgromnies
Jun 19, 2004

Begby posted:

Out of curiosity would you want the actual repository on your desktop?

There is a tool though called svnsync that will mirror it to a readonly copy. You can't commit changes to the mirror and then have it sync to the master though.

You can also use the 'svnadmin hotcopy' command if all you are going for is a copy of the repository.

Why can't you just rsync it? Isn't all the repository information contained in the .svn directories on the filesystem?

Dessert Rose
May 17, 2004

awoken in control of a lucid deep dream...

Pardot posted:

GitReady is great for looking up specific tasks, and github is the best source hosting site ever.

I only wish github would give me single-dev private repos free. But I can just use Dropbox, I suppose.

Pardot
Jul 25, 2001




Ryouga Inverse posted:

I only wish github would give me single-dev private repos free. But I can just use Dropbox, I suppose.

Check out gitosis for putting up a remote repo somewhere. I used to use that and it was fairly easy to set up. The neat thing about that is the config is stored in a git repo that you push to in order to make changes. But I recently got my company reimburse me for the $7/month. Honestly I should have just paid it all along, it's worth it.

slipped
Jul 12, 2001

Janin posted:

Bazaar has some very nice documentation, much of which is useful with other (D)VCS as well. Bazaar in five minutes and the user guide are worth a look.

Also, considering how large IBM is, I'm always surprised at how terrible their VCS tools (ClearCase and Continuus) are.

for what its worth, clearcase handles DB2 well, and I can't imagine git svn or any other RCS being able to handle a project of its size without some _serious_ changes to the current structure of things.

Zhentar
Sep 28, 2003

Brilliant Master Genius

sonic bed head posted:

I used "svn delete." The files are definitely not in the head revision of the trunk. Also, the merge command is exactly skipping the ones that have been deleted, so it must know that the deletions have happened.

I don't know about your particular issue, or the current state of SVN, but historically SVN hasn't handled merging updates to the trunk into branches and then back to the trunk very well. An alternative is to create a new branch from the trunk, and merge your changes from the original branch into the new branch.

Scaevolus
Apr 16, 2007

slipped posted:

for what its worth, clearcase handles DB2 well, and I can't imagine git svn or any other RCS being able to handle a project of its size without some _serious_ changes to the current structure of things.
The entire Linux kernel source history is in git, and I can't imagine DB2 is a larger project.

MonkeyMaker
May 22, 2006

What's your poison, sir?

Pardot posted:

[and github is the best source hosting site ever.

I really liked using unfuddle at my last job. Git or SVN hosting and smart commit-message parsing that ties into the ticket tracking.

Jargon
Apr 22, 2003

Ryouga Inverse posted:

I only wish github would give me single-dev private repos free. But I can just use Dropbox, I suppose.

It's totally worth paying $7 a month for GitHub, especially considering that if you have a blog you can save money by hosting it there with GitHub Pages and Jekyll without taking up an extra private repo: http://jarinheit.com/2009/02/16/simplified-blogging-with-github-pages-and-jekyll.html

Rapportus
Oct 31, 2004
The 4th Blue Man
Probably geared more toward enterprise users, but Perforce has a free license for 2 users. There's a great O'Reilly book for Perforce which provides plenty of cookbook-style useful tips and pitfalls. At work we use Perforce not only for source control but also as a transport mechanism between sites (replacing something like Rsync or Robocopy).

rotor
Jun 11, 2001

classic case of pineapple derangement syndrome

Zhentar posted:

I don't know about your particular issue, or the current state of SVN, but historically SVN hasn't handled merging updates to the trunk into branches and then back to the trunk very well. An alternative is to create a new branch from the trunk, and merge your changes from the original branch into the new branch.

this really should work though, and I'm certain that I've done this myself. I can't really imagine what would cause it to break, but I haven't had time to set up a test so meh.

Allie
Jan 17, 2004

For the Mercurial equivalent of GitHub there's BitBucket. In addition to unlimited public repos, you get one private repo for free, and you get bug trackers for each repo. You can also configure it to change tickets from commit messages, and it can integrate with CIA, Lighthouse, Basecamp, and other services.

And I believe with the pay plans you can use your own domain name with the service.

BusError
Jan 4, 2005

stupid babies need the most attention
Some might balk at the idea of paying :10bux: for a book on a VCS tool when there's so much free info out there, but "Git Internals" (https://peepcode.com/products/git-internals-pdf) from Peepcode helped me really understand how Git works a lot better than any of the other tutorials I've seen. I highly recommend it. (The author's screencasts are pretty good, too)

also

Ledneh posted:

our team uses clearcase for version control, dictated by higher management.
Oh god, I am so sorry. I work (not for much longer, I hope) in an rear end-backwards systems department that thinks IBM shits gold, and we're required to use like every tool they crank out...so far, no one has been able to figure out how to get ClearCase to do anything besides suck up hundreds of hours of time attempting to configure it properly.

Begby
Apr 7, 2005

Light saber? Check. Black boots? Check. Codpiece? Check. He's more machine than kid now.

ashgromnies posted:

Why can't you just rsync it? Isn't all the repository information contained in the .svn directories on the filesystem?

Rsync won't work, just like copying all the repository files won't work either while the repository is being accessed (you have to use svnadmin hotcopy). You can copy a working copy with no issues though.

I am not sure why, but I guess its kinda like if you try to copy the mysql data files while the server is running, you could end up with corrupted tables in the copy since not everything is flushed, queries are half done, etc.

deimos
Nov 30, 2006

Forget it man this bat is whack, it's got poobrain!
At work we just started using subversion (were using Serena Version Manager which is horribly bad), we went with subversion because it has more integration with other software (their requirement not mine) than mercurial/git (our second choices). Regardless, easy sailing so far with SVN.

My question is, what are good Subversion GUIs for OS X? I know there is Versions and svnX, but wanted to know you guys' experience with these and/or other tools. I am very comfortable with the command line and don't really care for SVN GUIs (although Tortoise has spoiled me silly), but my team isn't so inclined.

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


BusError posted:

Oh god, I am so sorry. I work (not for much longer, I hope) in an rear end-backwards systems department that thinks IBM shits gold, and we're required to use like every tool they crank out...so far, no one has been able to figure out how to get ClearCase to do anything besides suck up hundreds of hours of time attempting to configure it properly.

Yeah, we're all quite saddened by it too. But whaddaya gonna do besides spend money we don't have on a new suite? vOv

That said, for a couple guys who have no training in the thing and spend most of their time programming anyway, I think my partner and I have a sufficient handle on it. But oh, man, trying to explain to the other developers what they need to do when they have code ready to migrate... :suicide:

Begby
Apr 7, 2005

Light saber? Check. Black boots? Check. Codpiece? Check. He's more machine than kid now.

deimos posted:

My question is, what are good Subversion GUIs for OS X? I know there is Versions and svnX, but wanted to know you guys' experience with these and/or other tools. I am very comfortable with the command line and don't really care for SVN GUIs (although Tortoise has spoiled me silly), but my team isn't so inclined.

I wasn't too impressed with svnX.

We did license SmartSVN for a time, its Java based so its cross platform - http://www.syntevo.com/smartsvn/index.html. It seemed kinda slow and clunky. Sometimes updating took way way too long.

I can't remember which one, but it was either svnX or SmartSVN that had the subversion libraries statically linked. That means that even if you upgraded the SVN client on your mac, the SVN GUI would still use the old version and you had to wait for them to update it. Dunno if that was fixed or not.

I did try versions for a bit and it seemed a ton better, then we migrated most of our work from PHP to C#, so I haven't really messed with it for awhile.

There is also a tortoise like extension for Mac available on tigris.org that adds the commands to the context menu. However, they are two menus deep. If I could get them into the top level menu, then it would a lot more usable.

MononcQc
May 29, 2007

One architect where I work has got some kind of idea he suggested on the corner of a table a few weeks ago, basically replacing the database back-end of a web-service for text and html documents with either git or mercurial.

Past the loss of full-text search (which could possibly be done anyway by decoupling stuff) and the fact it is hackish to no end, the idea didn't sound that bad; you get versioning for your documents, can distribute and sync them, can use permissions, can edit them even if offline, etc.

Basically all the advantages of a DCVS, but applied to text documents. With caches and the behaviour of key-value storage, He judged decent speeds could be achieved for anything RESTful, except maybe for the document creation and problems of conflicts.

There are obvious downsides to this concept, and people do use all kinds of databases instead of version control for a reason. However, there are some clear upsides to it, which would push me to prototype something with a similar system for fun at home.

Have anyone ever heard of a similar project being done? I'm looking for success and/or atrocious failure stories.

deimos
Nov 30, 2006

Forget it man this bat is whack, it's got poobrain!

MononcQc posted:

One architect where I work has got some kind of idea he suggested on the corner of a table a few weeks ago, basically replacing the database back-end of a web-service for text and html documents with either git or mercurial.

Past the loss of full-text search (which could possibly be done anyway by decoupling stuff) and the fact it is hackish to no end, the idea didn't sound that bad; you get versioning for your documents, can distribute and sync them, can use permissions, can edit them even if offline, etc.

Have anyone ever heard of a similar project being done? I'm looking for success and/or atrocious failure stories.

Why not use a document database like CouchDB or ThruDB? ThruDB seems specially oriented toward what you want.

MononcQc
May 29, 2007

deimos posted:

Why not use a document database like CouchDB or ThruDB? ThruDB seems specially oriented toward what you want.

I'm not looking for anything in particular, but just at the possibility of doing it "Because I can."

There would be all kinds of scaling complications like sharding, size of directories and access time (mostly what services like akamai must go through), etc. which would make it impractical for anything but a small personal blog or for a similar concept.

The whole idea is still interesting as far as toying goes, in my opinion.

Slurps Mad Rips
Jan 25, 2009

Bwaltow!

I recently got into a debate with a friend of git v. bzr.

I did some research, but can anyone tell me (other than an "easier" to use interface, as to why I would want to use bzr over git?

TOO SCSI FOR MY CAT
Oct 12, 2008

this is what happens when you take UI design away from engineers and give it to a bunch of hipster art student "designers"

SAHChandler posted:

I recently got into a debate with a friend of git v. bzr.

I did some research, but can anyone tell me (other than an "easier" to use interface, as to why I would want to use bzr over git?

It's got a stable API, so instead of having to write extensions by parsing output from other commands, you just import bzrlib.

You can give each branch its own directory, so generated temporary files won't get mixed up between branches.

It tracks file renames, which is *very* useful for versioning non-text (images, compressed files, external libraries, etc).

It works well on Windows, without having to install a Linux emulation layer, and comes with a GUI if that's your bag.

Filburt Shellbach
Nov 6, 2007

Apni tackat say tujay aaj mitta juu gaa!

MononcQc posted:

There would be all kinds of scaling complications like sharding [...] which would make it impractical for anything but a small personal blog or for a similar concept.

I hate that everyone is so obsessed with scaling. If you make it as big as Google then you can afford to worry about scaling. Killing novel ideas because they might not scale to thousands of concurrent users is ridiculous.

Xenos
Jun 17, 2005

deimos posted:

My question is, what are good Subversion GUIs for OS X? I know there is Versions and svnX, but wanted to know you guys' experience with these and/or other tools. I am very comfortable with the command line and don't really care for SVN GUIs (although Tortoise has spoiled me silly), but my team isn't so inclined.

I use Versions at my job, which works fine for me. It completely outclasses all the free options. Cornerstone is always an option, too, but it doesn't really feel right to me.

bitprophet
Jul 22, 2004
Taco Defender

Janin posted:

It tracks file renames, which is *very* useful for versioning non-text (images, compressed files, external libraries, etc).

Can't comment on the rest (besides making a snide "who gives a poo poo about Windows?" taunt, and mention that Mercurial is supposed to have good Windows support too) but Git tracks file renames just fine, as far as I can tell?

I'm afraid Bazaar is looking like it's going to lose out to Mercurial and Git, sadly for Bazaar users / Ubuntu / Canonical. I don't know anybody who's choosing it over the other two unless they were an early adopter before Mercurial basically overtook it in popularity. Python itself has gone with Mercurial. Etc.

Which I find interesting, since even a year ago (or even less) it seemed more like a 3-way tie with no clear winner. I wonder if Git/Mercurial will ever see a clear winner or if they'll end up balancing out somehow.

TOO SCSI FOR MY CAT
Oct 12, 2008

this is what happens when you take UI design away from engineers and give it to a bunch of hipster art student "designers"

bitprophet posted:

Can't comment on the rest (besides making a snide "who gives a poo poo about Windows?" taunt, and mention that Mercurial is supposed to have good Windows support too) but Git tracks file renames just fine, as far as I can tell?

Git only tracks file contents, so when a binary file is both renamed and modified, it's usually treated as a completely different file. This can make it difficult to track things like "who added this image to the project?".

Filburt Shellbach
Nov 6, 2007

Apni tackat say tujay aaj mitta juu gaa!
That this is the first mention of darcs makes me sad.

TOO SCSI FOR MY CAT
Oct 12, 2008

this is what happens when you take UI design away from engineers and give it to a bunch of hipster art student "designers"

Sartak posted:

That this is the first mention of darcs makes me sad.

misery.sh

Allie
Jan 17, 2004

Janin posted:

It's got a stable API, so instead of having to write extensions by parsing output from other commands, you just import bzrlib.

You can give each branch its own directory, so generated temporary files won't get mixed up between branches.

It tracks file renames, which is *very* useful for versioning non-text (images, compressed files, external libraries, etc).

It works well on Windows, without having to install a Linux emulation layer, and comes with a GUI if that's your bag.

Mercurial does all of this as well.

My first DVCS was darcs. It was great, very intuitive, especially being patch-based. I did run into ridiculous performance issues, and corrupted my repository on a couple of occasions. I don't remember exactly how I happened upon Mercurial, but I've been happy since switching.

I tried out Bazaar a couple of times around that time period. I kept seeing it being touted as the most user friendly DVCS out there, but honestly I didn't find it any more friendly that Mercurial. The lack of a built-in repository web application was a killer too - nothing compares to "hg serve". The constant format changing was also disconcerting, and the performance was lacking at the time.

I remember reading that sometime in the past Mercurial and Bazaar were poised to merge, but Canonical shot down the whole idea. I think they're going to find themselves slipping into obscurity very quickly if they don't catch up to Git and Mercurial soon.

But I do have to say, I just can't imagine going back to Subversion ever again. I know it's ubiquitous and I know many people say it works perfectly fine. But after having the ability to do all my versioning locally, I just can't go back to that. And I've found that if you try to do concurrent development on the same branch with other people, it gets very ugly.

Allie fucked around with this message at 05:50 on Apr 17, 2009

uXs
May 3, 2005

Mark it zero!
We use SourceSafe (but we're looking to switch.)

I have this project where I had the urgent (and temporary) need to have a version control system that has excellent support for branching and merging, so since a week or 2 I've been using Git locally (I'm the only developer on this project for the moment.)

So far it has worked really well and it's too bad I won't be able to recommend it for use for the entire group because of the substandard Windows support. :(

I'm going to check out Mercurial and Subversion, and choose between those two.

Adbot
ADBOT LOVES YOU

bitprophet
Jul 22, 2004
Taco Defender

Janin posted:

Git only tracks file contents, so when a binary file is both renamed and modified, it's usually treated as a completely different file. This can make it difficult to track things like "who added this image to the project?".

Right, my point is that I think you're working off of old info. I just made a random binary file with dd and then 1) added it as-is, 2) renamed it without modifying it, and 3) renamed AND modified it in the same commit.

During that process, git status was showing me the right information (i.e. detecting a rename instead of showing an add + delete) and git log is capable of following the file's entire history:
code:
user@host:/tmp/testrepo $ git log --follow binaryfile3.bin
commit 0d29f9a521d5a7dfe2e6b6356036cac3a6ef2eb4
Author: User Name <user@domain.org>
Date:   Fri Apr 17 10:44:00 2009 -0400

    modified AND renamed

commit fadee12297956c2782b510ae7d278b11558a4ce5
Author: User Name <user@domain.org>
Date:   Fri Apr 17 10:43:02 2009 -0400

    renamed

commit 61c2bc22b1c41eda55aab607a5653c1dabaae931
Author: User Name <user@domain.org>
Date:   Fri Apr 17 10:42:30 2009 -0400

    added binary file
user@host:/tmp/testrepo $ 
Now, all that said, yea, Git certainly has its share of pitfalls and warts -- I'm not saying it's perfect! Just clearing up what I see as a misconception. Git's definitely geared towards text and has been since its start, but I think it's gotten a lot better about that, and other things, over the past year or so.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply