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
TronPaul
Oct 11, 2012
Wouldn't it be better to test each changeset atomically? Testing on a combination of changesets that have been merged into test would make it hard to find which branch or branches are causing issues or problems.

What might be worthwhile is have the test server serve as more of a beta build. Then the workflow can go dev of branch -> test branch atomically -> beta (test server) -> live.

Adbot
ADBOT LOVES YOU

Golbez
Oct 9, 2002

1 2 3!
If you want to take a shot at me get in line, line
1 2 3!
Baby, I've had all my shots and I'm fine

TronPaul posted:

Wouldn't it be better to test each changeset atomically? Testing on a combination of changesets that have been merged into test would make it hard to find which branch or branches are causing issues or problems.
You'd think, but our site is mostly atomic. We don't have much of a framework that ties everything together.

And also: If a branch is causing problems with another branch then that's definitely something to find out before we go live, right? So we'd need a beta server, as you say below, except I'd rather have people outside IT, who aren't technical and have limited time, to have to test something only once rather than say "okay, you tested it... now test it again!".

quote:

What might be worthwhile is have the test server serve as more of a beta build. Then the workflow can go dev of branch -> test branch atomically -> beta (test server) -> live.

We throw up major major new branches in their own domain, though we haven't had one of those since switching to git.

Blotto Skorzany
Nov 7, 2008

He's a PSoC, loose and runnin'
came the whisper from each lip
And he's here to do some business with
the bad ADC on his chip
bad ADC on his chiiiiip
So we had a meeting yesterday where it was eventually decided that we'd be allowed(!) to continue using git in development engineering so long as we also checked major versions into MS Visual SourceShredder for production & QC to have. Everybody wins :unsmith:

Hughlander
May 11, 2005

Otto Skorzeny posted:

So we had a meeting yesterday where it was eventually decided that we'd be allowed(!) to continue using git in development engineering so long as we also checked major versions into MS Visual SourceShredder for production & QC to have. Everybody wins :unsmith:

Sounds like you should be in the coding horror thread instead. Actually I wonder if there would be enough interesting content for a process horror thread. Probably if it was at the SH/SC level.

Doc Hawkins
Jun 15, 2010

Dashing? But I'm not even moving!


Golbez posted:

And also: If a branch is causing problems with another branch then that's definitely something to find out before we go live, right? So we'd need a beta server, as you say below, except I'd rather have people outside IT, who aren't technical and have limited time, to have to test something only once rather than say "okay, you tested it... now test it again!".

Ohhhh! So these are manual tests?

If so, then all is clear. Carry on, and may God have mercy on your souls.

Golbez
Oct 9, 2002

1 2 3!
If you want to take a shot at me get in line, line
1 2 3!
Baby, I've had all my shots and I'm fine

Doc Hawkins posted:

Ohhhh! So these are manual tests?

If so, then all is clear. Carry on, and may God have mercy on your souls.

Right, I'm only talking about user testing. Internal/automated/unit testing is an entirely different thing.

what unit tests

Blotto Skorzany
Nov 7, 2008

He's a PSoC, loose and runnin'
came the whisper from each lip
And he's here to do some business with
the bad ADC on his chip
bad ADC on his chiiiiip
The IDE that I and my coworker are using for a project contains a schematic-like binary file in each project. How can I get Git to always cause a merge conflict on this file if both branches in the merge have changed it?

Cat Plus Plus
Apr 8, 2011

:frogc00l:

Otto Skorzeny posted:

The IDE that I and my coworker are using for a project contains a schematic-like binary file in each project. How can I get Git to always cause a merge conflict on this file if both branches in the merge have changed it?

Unless something changed recently, binary files are never merged and always left as conflicts by default.

OnceIWasAnOstrich
Jul 22, 2006

I have two git repositories from a project. Sometime in the past I decided it would be a good idea to split the project in two, one for the program that does the work and generates the results, and the other for the web-app for viewing of the results, thinking that I would just run the webapp myself and let people get text-only results from the program. After I did some more building I realized my CherryPy webapp worked just fine on anyones computer and it was easy enough to configure it to work both locally and on a server. I now want to merge those two completely different repositories back into one...and I have no idea how to do this. They are both on Github if they have some sort of hidden tool for doing this that would help. What would be the best way to keep all of my git-history but have these two projects be merged into one?

edit: Turning it into a submodule seems to be working out as long as I remember not to edit the submodule folder.

OnceIWasAnOstrich fucked around with this message at 21:59 on Nov 13, 2012

ufarn
May 30, 2009
Submodule question.

Is there a way to just add the files from a repo, and not the repo files in a folder?

And is there a way to cherry-pick a single or few files from a repo instead of all of them?

Hughlander
May 11, 2005

OnceIWasAnOstrich posted:

edit: Turning it into a submodule seems to be working out as long as I remember not to edit the submodule folder.

What do you mean by not edit the submodule folder? You can edit the code that's in a submodule, you should just check it out to a branch first. I work all day on a library that's a submodule in about 5 projects, what I normally do is go to a test project that contains the submodule, cd into the submodule dir, then checkout master there. I'll do all my work there, commiting there, then pushing the submodule master to github. At that point then I'll go back a directory, git add the submodule dir, commit and push that to update the ref that the submodule points at. As other teams want to use the latest module they'll either checkout a tag, or the head of master, and then update the submodule ref as well based on what they just checked out.

good jovi
Dec 11, 2000

'm pro-dickgirl, and I VOTE!

OnceIWasAnOstrich posted:

edit: Turning it into a submodule seems to be working out as long as I remember not to edit the submodule folder.

Check out subtrees. There's the 'git subtree' command, which is what I would use, and there's something called subtree merging that I don't understand, and I don't know if its actually related.

OnceIWasAnOstrich
Jul 22, 2006

Hughlander posted:

What do you mean by not edit the submodule folder? You can edit the code that's in a submodule, you should just check it out to a branch first. I work all day on a library that's a submodule in about 5 projects, what I normally do is go to a test project that contains the submodule, cd into the submodule dir, then checkout master there. I'll do all my work there, commiting there, then pushing the submodule master to github. At that point then I'll go back a directory, git add the submodule dir, commit and push that to update the ref that the submodule points at. As other teams want to use the latest module they'll either checkout a tag, or the head of master, and then update the submodule ref as well based on what they just checked out.

Since both of these things are my projects I have just been editing the submodule as a main project in its original folder and pushing master to github and when I want to use any changes pulling them in the submodule folder then running submodule update. This is probably because I'm not a programmer and don't actually understand git or branches and my version control method consists of myself committing changes to master every time I change something and it passes the tests. just now figured out how branches work and wow they are really convenient...

I looked at subtrees but it looks like it is some sort of external program not built into git? I dismissed it because Heroku would automatically pull both my module and my submodule and I wasn't sure if it would be able to do the same thing with subtrees.

OnceIWasAnOstrich fucked around with this message at 18:26 on Nov 14, 2012

good jovi
Dec 11, 2000

'm pro-dickgirl, and I VOTE!

OnceIWasAnOstrich posted:


I looked at subtrees but it looks like it is some sort of external program not built into git? I dismissed it because Heroku would automatically pull both my module and my submodule and I wasn't sure if it would be able to do the same thing with subtrees.

The subtree command is built in to git since 1.7.11, I think. It'll work fine with Heroku, since it becomes just a normal part of the tree.

sephiroth838
Aug 24, 2012

Hughlander posted:

Sounds like you should be in the coding horror thread instead. Actually I wonder if there would be enough interesting content for a process horror thread. Probably if it was at the SH/SC level.

I'd post there....I worked with SEPG at a CMMI company for 6 years before joining a SCRUM company. Things are so different, yet the same work gets done.

sephiroth838
Aug 24, 2012
For those that don't know yet, Microsoft created a Team Foundation Server Express version which supports teams up to 5. So if you are in a microsoft shop or want to mess around with it at home you can now for free.

It is for TFS 2012, but VS 2010 can still connect to it.

Wheany
Mar 17, 2006

Spinyahahahahahahahahahahahaha!

Doctor Rope
Imma bump this thread since I didn't want to add to the coding horros thread derail:

Okay, so git is good for text files that change often and small binaries that do not change?

Since I'm a coder, I didn't even think of any other use-case before, but when it was mentioned, it made perfect sense for 3d models and textures and such to be added to version control.

So what do animation/games companies use for version control? Is it proprietary? Are there free alternatives? What sorcery do these systems use for merging/conflict resolution/managing the size of commits/repositories when using binary files? ("Why are they better for binaries than git etc?")

pseudorandom name
May 6, 2007

Bungie's contract with Activision stipulates that Activision will supply them with sufficient Perforce licenses to complete their project.

Hughlander
May 11, 2005

Wheany posted:

Imma bump this thread since I didn't want to add to the coding horros thread derail:

Okay, so git is good for text files that change often and small binaries that do not change?

Since I'm a coder, I didn't even think of any other use-case before, but when it was mentioned, it made perfect sense for 3d models and textures and such to be added to version control.

So what do animation/games companies use for version control? Is it proprietary? Are there free alternatives? What sorcery do these systems use for merging/conflict resolution/managing the size of commits/repositories when using binary files? ("Why are they better for binaries than git etc?")

Every company I've been at other than my current mobile game studio has used perforce. Even that company as I mentioned in the other thread has at least one game that uses p4 for source assets. Coworker was just interviewing at blizzard and apparently the SC2 team uses svn, but the new MMO team uses Github enterprise. (Bring github website in house.) On an MMO I was on in the early 2000s, there was a CI build system that commited to an 'unstable' branch in p4. QA would look at the unstable builds and if they were good enough for a release would merge it to a stable branch. That unstable branch was set to only keep the last 100 or so builds.

Another company I was at had a single common repository for all source code across all projects, and then source/cooked arts assets/full builds in project specific repos (That were also set up as separate perforce replication servers though I think there was a master server in the background.) In that case content/QA would just sync from the project specific repos, while engineers would have one directory with the content specific poo poo, then the build step of the source would overwrite the exes from a different directory that was in the common engineering repository.

ani47
Jul 25, 2007
+
As Hughlander most I know of use p4. Most/all of EA studios use it (I think they have a global license) along with sony's studios. But there are odd ones that are different - e.g. I believe media molecule use svn. It's pretty expensive to change source control so if you stick with the same engine/pipeline for years (as many studios have done through ps3/360 gen) then they're most likely going to stick with the same source control too.

Thern
Aug 12, 2006

Say Hello To My Little Friend
What do you guys use for managing and browsing your git repositories (ala github)?

We are trying to make the move from using SVN to git, so I set up a server for our repos and serve them out via HTTP using git-http-backend (due to ACL issues). For now I plan to setup up a wiki with a list of all the repos and links to them. But I wanted to see if there was something better I could use instead.

I'm currently looking at Gitlist, and gitorius, but I wanted to know if anyone else had some suggestions.

ufarn
May 30, 2009
GitHub is pretty great, although the interface takes some getting used to.

The real forté of GitHub is its Issues and Pull Request system, which creates a fantastic workflow, once you get the hang of it. Especially if you know how to use Milestones.

Thern
Aug 12, 2006

Say Hello To My Little Friend
Sorry if I wasn't clear, but we can't use Github since it is external, and they don't want to pay for the enterprise version.

good jovi
Dec 11, 2000

'm pro-dickgirl, and I VOTE!

I've heard good things about Atlassian's Stash. It's quite a bit cheaper than Github:Enterprise (which is excellent and we use at work).

Edison was a dick
Apr 3, 2010

direct current :roboluv: only

Thern posted:

What do you guys use for managing and browsing your git repositories (ala github)?

We are trying to make the move from using SVN to git, so I set up a server for our repos and serve them out via HTTP using git-http-backend (due to ACL issues). For now I plan to setup up a wiki with a list of all the repos and links to them. But I wanted to see if there was something better I could use instead.

I'm currently looking at Gitlist, and gitorius, but I wanted to know if anyone else had some suggestions.

My workplace sponsored one of our senior engineer's personal projects, so we have an open-source, Access Controlled git server, with its configuration version controlled in git.

It's called gitano, is written in lua, and has sandboxes for running hooks in lua.
I like it because you don't need to use a web interface to do anything as it has a command
line interface.
Our company git server doesn't even have a web interface.

Unfortunately there doesn't yet exist sufficient documentation for it to be easy to set up.

ufarn
May 30, 2009

Sailor_Spoon posted:

I've heard good things about Atlassian's Stash. It's quite a bit cheaper than Github:Enterprise (which is excellent and we use at work).
Atlassian also own BitBucket, so it's bound to be pretty grat.

Cat Plus Plus
Apr 8, 2011

:frogc00l:

Thern posted:

I'm currently looking at Gitlist, and gitorius, but I wanted to know if anyone else had some suggestions.

GitLab is pretty nice.

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe
cgit and gitolite?

Thern
Aug 12, 2006

Say Hello To My Little Friend
Thanks a lot for the suggestions everyone, I'll be sure to check them out!

TheReverend
Jun 21, 2005

Time for a very vague and very broad question!


I work in a very very very small shop. It's me and one other guy and that other guy is a part time college student.
I've been working here since the dawn of time and it was just me and I used Bitbucket/Mecurial (on advise from a goon in this thread) to keep track of all of my changes.

I learned just enough to be familiar with pushing my commits to Bitbucket. This kept my source code offsite and secure. With this new guy, we're constantly fixing things and his changes lack my changes, etc etc. I'm pretty sure we're not using it properly and with more training we could use it effectively and efficiently.

All this trouble has made me and my boss thinking maybe Github would be easier to use.

So my questions are, I guess, when should someone use Mecurial and when should they use github? I think Github might be easier to use?

Any insight?

Lumpy
Apr 26, 2002

La! La! La! Laaaa!



College Slice

TheReverend posted:

Time for a very vague and very broad question!


I work in a very very very small shop. It's me and one other guy and that other guy is a part time college student.
I've been working here since the dawn of time and it was just me and I used Bitbucket/Mecurial (on advise from a goon in this thread) to keep track of all of my changes.

I learned just enough to be familiar with pushing my commits to Bitbucket. This kept my source code offsite and secure. With this new guy, we're constantly fixing things and his changes lack my changes, etc etc. I'm pretty sure we're not using it properly and with more training we could use it effectively and efficiently.

All this trouble has made me and my boss thinking maybe Github would be easier to use.

So my questions are, I guess, when should someone use Mecurial and when should they use github? I think Github might be easier to use?

Any insight?

Using got or mercurial won't make a difference, as your workflow won't change much. Assume you have a repo on BitBucket, and your code on your machine is exactly the same (probably because you pushed your code to BitBucket!) Here's how things work when other guy starts working with you:

Other guy gets a copy of the repo by cloning it from BitBucket
You start making some changes. You commit frequently while working...
He starts making some changes. He commits frequently while working...
You finish your changes, do a final commit and push your changes to the repo.
You say "HEY OTHER GUY, I PUSHED CHANGES!"*
Other guy gets to a happy place, commits, then pulls changes, and merges anything that wasn't auto-merged.
Other guy finishes his changes, does a final commit and pushes.
Other guy says "HEY YOU, I PUSHED CHANGES!@"*
You commit if you have any local changes, pull and merge.
Your and he marvel at the fact that your code looks exactly the same
Rinse, repeat

* mercurial will actually tell you this with an error / warning if you try to push if there are changes you don't have yet (I imagine git has the same, but I'm not a git person), but at the start, practice telling each other when you pushed to foster communication and notice when he hasn't pushed in 4 weeks...

Here's a not too terrible mercurial tutorial (despite benig by Splosky) that deals with multi-user workflows: http://hginit.com/02.html EDIT: BitBucket would take the place of the 'Central Repo' in his tutorial)

\/\/ You are right! I assumed they would be committing frequently while working, but I should add that explicitly. Edited to reflect that...

Lumpy fucked around with this message at 22:48 on Jan 21, 2013

uXs
May 3, 2005

Mark it zero!
So other guy merges your changes while he hasn't commited his own changes yet? That is so horrible.

What if he fucks up the merge? Then he just lost his own changes.

First commit, then merge. (And commit the merge, obv.)

Thern
Aug 12, 2006

Say Hello To My Little Friend
He's a college kid, he probably doesn't know any better. Sitting down with him and working out a workflow for the two of you would be far more effective then trying to solve the problem with technology.

TheReverend
Jun 21, 2005

Well I think we're pushing and cloning so... yeah we're doing this very very wrong.

I just have so much non-administrative stuff (coding) to do that I don't like to take too much time being a manager.

Which I guess I am so time to bite the bullet.

Thanks guys.

Janitor Prime
Jan 22, 2004

PC LOAD LETTER

What da fuck does that mean

Fun Shoe
The tortoisehg client I'm using won't let me pull newer versions unless I commit or discard my changes. However I'm using the fetch extension which might or might not be affecting this behavior.

wwb
Aug 17, 2004

Get the kid to work in a branch and encourage him to commit early and often.

Committing bad changes is A-OK, pushing bad changes into default / master / trunk is where you run into trouble.

ufarn
May 30, 2009
I'm playing around with .slugignore, and I'm running into a weird problem: when I used my filter in .gitignore, the files are properly ignored, but when I use them in .slugignore, nothing happens; the slug size and number of compressed files remain the same upon push as before I created the .slugignore file.

.slugignore file here: http://pastebin.com/MnF3b9wt.

This would lead me to think that .slugignore just doesn't work, but applying wildcard extension filters like *.png manages to bring the size and file number down, so it does work on some level; there is just something off.

Folders deprecated/ and avatars/ are not at root level, but deeper down inside FWIW.

Pardot
Jul 25, 2001




Try without the trailing slash. Also if the other dirs aren't at the root level you may have to specify their full path. Also also slugignore is (as far as I know) a Heroku specific thing, not a general tool. I'm happy to help dig into this with you, but you'll probably have better luck with support.

ufarn
May 30, 2009
I'm finding it really hard to do some testing for this. I'm doing a billion commits back and forth, but I'm not sure how to test against this locally.

Regardless of what I do, I'm told that 109 static files were copied, but the slug varies in sizes - sometimes even if the .slugignore file is empty.

This stuff drives me crazy.

Adbot
ADBOT LOVES YOU

Pardot
Jul 25, 2001




ufarn posted:

I'm finding it really hard to do some testing for this. I'm doing a billion commits back and forth, but I'm not sure how to test against this locally.

Regardless of what I do, I'm told that 109 static files were copied, but the slug varies in sizes - sometimes even if the .slugignore file is empty.

This stuff drives me crazy.

I probably can't post the direct source code, but looking at it, it treats each line that isn't a comment as a shell glob, an d if the file exists, deletes it. So test your lines as shell globs locally.

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