|
The version control chat is exactly what I need to be reading right now. When we come back from the holiday break, I'm training our little team about version control. The "daily dump" analogy may make it onto a powerpoint slide.
|
# ? Dec 28, 2013 17:00 |
|
|
# ? May 29, 2024 19:23 |
|
EAT THE EGGS RICOLA posted:Or when someone tells you to hard reset your local repo, you should maybe just consider that it's going to blow away everything? It's not like Horatio ran the command, he gave it to this person, who said "okay that seems reasonable", knowing that they only commit work once a week. I feel responsible not because I physically typed the command but because this guy knows nothing about git and would have typed anything I told him to (despite the fact that he's been "using" git for years and I just started learning it a year ago). So here's the thing, he doesn't know what's happened yet. Pushing out my fix was the last thing we did Friday before leaving and I had that moment of dawning horror on the way home when I remembered he's allergic to regular commits. He doesn't know yet that the work is lost. Do I own up to it or do I just say "gosh that's awful, don't know how that happened, let me help you recreate your changes and by the way here's a tutorial on how to actually use git"?
|
# ? Dec 28, 2013 17:00 |
|
HORATIO HORNBLOWER posted:I feel responsible not because I physically typed the command but because this guy knows nothing about git and would have typed anything I told him to (despite the fact that he's been "using" git for years and I just started learning it a year ago). Stop, no, don't. You are not responsible for your incompetent coworker. You can't make somebody learn who clearly doesn't care.
|
# ? Dec 28, 2013 17:10 |
|
Since everyone is talking about git, is there a GUI client that actually has any of the features? The Visual Studio 2013 integration and the Github client both only offer the absolute basics but I don't really want to devote a whole lot of time to learning git commands on a sample and I certainly don't want to test out commands I don't really understand on my actual work
|
# ? Dec 28, 2013 17:13 |
|
HORATIO HORNBLOWER posted:I feel responsible not because I physically typed the command but because this guy knows nothing about git and would have typed anything I told him to (despite the fact that he's been "using" git for years and I just started learning it a year ago). I would probably go with "well yeah that's what 'reset --hard' does what did you expect it's right in the name, aren't you committing multiple times a day like you're supposed to?" Or maybe "Oh that sucks a bit but at least your last commit was just a couple hours earlier at worst"
|
# ? Dec 28, 2013 17:18 |
|
HORATIO HORNBLOWER posted:I feel responsible not because I physically typed the command but because this guy knows nothing about git and would have typed anything I told him to (despite the fact that he's been "using" git for years and I just started learning it a year ago). Though his lovely backup/commit practices are the real issue here, you should still own up to what's really happened. If you don't, there's basically two possible outcomes:
If the first happens, do you think it will be better for you to have not owned up? (I bet "no") If the second happens, do you think he's more likely to say "Oh, whoops, I guess I should spend some time learning this tool" or "What the hell, now I don't trust Git at all, better figure out some backwards-rear end system that keeps my in progress code outside of a local repository so this can't happen again"? If the guy were willing to learn his tools you wouldn't be here in the first place. I've seen the second one happen twice in my workplace and it sucks trying to work with people doing that. Yes, not being willing to learn the tools you're using is The Real Coding Horror™, but you won't be able to fix that problem in your co-workers (besides by switching jobs) so you should at least go with the path that makes them easier for you to work with in the future (hint, it's not the one that involves a backwards-rear end manual-copying-based idea of a "version control system"). Explain what happened and how to make it not a problem in the future, or he's as likely as not to make up a much more horrifying way to make it "not a problem" in the future.
|
# ? Dec 28, 2013 17:33 |
|
Jewel posted:Oh man these are neat. I really gotta learn about git properly one day but it's hard to learn without a codebase and someone to help, so I probably won't get a chance to until I get a job/internship. I've mostly used svn/perforce to this day so I know about most stuff, just not the advanced ones like those. The thing is that branches aren't really anything, they're just pointers to other commits, on wheels. git has a fundamentally different model from other VCSes and it's really cool and useful. https://people.gnome.org/~federico/news-2008-11.html#pushing-and-pulling-with-git-1
|
# ? Dec 28, 2013 18:22 |
|
EAT THE EGGS RICOLA posted:I would probably go with "well yeah that's what 'reset --hard' does what did you expect it's right in the name, aren't you committing multiple times a day like you're supposed to?" Horatio is being a non-lovely empathetic human being. Giving him smarmy comments to make back at his coworkers isn't going to help him or his relationship with his coworker. You sound like an unpleasant person to work with Horatio, just apologize and tell your coworker that they should be committing much more often. e: Basically I agree with brosmike QuarkJets fucked around with this message at 19:26 on Dec 28, 2013 |
# ? Dec 28, 2013 19:24 |
RICHUNCLEPENNYBAGS posted:Since everyone is talking about git, is there a GUI client that actually has any of the features? The Visual Studio 2013 integration and the Github client both only offer the absolute basics but I don't really want to devote a whole lot of time to learning git commands on a sample and I certainly don't want to test out commands I don't really understand on my actual work Atlassian SourceTree is pretty good. It's not perfect, and you will have to go command-line for some things, but it certainly helped me understand git better, and I think it gives a quite clear overview of what's actually happening in the repository.
|
|
# ? Dec 28, 2013 19:31 |
|
Brain Candy posted:Stop, no, don't. You are not responsible for your incompetent coworker. You can't make somebody learn who clearly doesn't care. I think you are at least in part responsible for the effects of commands you type into your co-worker's computer, even though, yes, he shouldn't have put himself in that position.
|
# ? Dec 28, 2013 20:04 |
|
Seconding SourceTree. It's nice to be able to actually "see" the repository, and it has GUI interfaces to most of the tools of git. That coworker's situation does suck, hopefully at least he remembers to tell people when he has large uncommitted work, or at least does git stash before anything potentially dangerous to uncommitted changes. carry on then fucked around with this message at 20:16 on Dec 28, 2013 |
# ? Dec 28, 2013 20:14 |
|
RICHUNCLEPENNYBAGS posted:I think you are at least in part responsible for the effects of commands you type into your co-worker's computer, even though, yes, he shouldn't have put himself in that position. That might be true if that were what happened. Instead, we have somebody seriously stressing about giving good info based on completely reasonable but wrong assumptions. This is the definition of "poo poo happens". If the guy asks wtf happened and wants make sure it doesn't happen again, sure, help him out. Should Horatio go to that dumb motherfucker hat in hand for making the mistake of assuming he was a professional? Unless Horatio is actually in some position of authority, (hint, he's not or the policy would be to always be committing) trying to tell someone else how to do their job is just going to cause resentment.
|
# ? Dec 28, 2013 20:43 |
|
QuarkJets posted:Horatio is being a non-lovely empathetic human being. Giving him smarmy comments to make back at his coworkers isn't going to help him or his relationship with his coworker. You sound like an unpleasant person to work with I was being mostly flippant, but this person hosed up, not Horatio. He should be helpful, but his coworker needs to learn how to do his job properly.
|
# ? Dec 28, 2013 21:41 |
|
He does, but the usual goon strategy of "publicly chastise with pithy comments" doesn't exactly foster a happy work environment. What I'd do is just mention that it occurred to me that uncommitted changes might have been lost only after performing the operation, and that I don't know how much was uncommitted. If he lost a lot, hopefully it'll be a good learning experience to commit often since, like someone said earlier, what would be different if his HDD had died instead? Accidents happen, work is lost, but hopefully he learns to commit more often for his own good. If not, this'll just keep happening.
|
# ? Dec 28, 2013 21:54 |
|
EAT THE EGGS RICOLA posted:I was being mostly flippant, but this person hosed up, not Horatio. He should be helpful, but his coworker needs to learn how to do his job properly. I definitely agree with that. If you find a coworker who's committing weekly, talk to them about the importance of committing much more frequently than that.
|
# ? Dec 28, 2013 22:22 |
|
QuarkJets posted:I definitely agree with that. If you find a coworker who's committing weekly, talk to them about the importance of committing much more frequently than that.
|
# ? Dec 28, 2013 23:11 |
|
Braaam posted:Rather than squashing, consider an interactive rebase as a middle-ground between the two (that is, between one giant squash commit and lots of tiny broken commits). You can use it to squash arbitrary commits into each other, re-order commits, remove commits entirely, and so on. What is the difference between what you do versus say: git rebase origin/master (obviously assuming origin/master is what you're trying to rebase on top of)?
|
# ? Dec 28, 2013 23:59 |
|
Shouldn't someone be managing the codebase to minimize these issues? I would have thought using a distributed VCS like git would mandate such an organizer for larger/mission-critical projects (like git itself)? Or is that an outmoded practice and we're assuming coders do all their own work now?
|
# ? Dec 29, 2013 00:07 |
|
There are two distinct concepts involved: having someone vet the code being merged into master, and having a dedicated person actually doing the merge. The first is still very important for anything large, whether it take the form of formal code reviews or a just person (or group of people) that has to sign off on changes, but the second is a sign that your process is hosed (if merging is difficult, you're using bad tools or doing it too rarely).
|
# ? Dec 29, 2013 00:45 |
|
ewe2 posted:Shouldn't someone be managing the codebase to minimize these issues? I would have thought using a distributed VCS like git would mandate such an organizer for larger/mission-critical projects (like git itself)? Or is that an outmoded practice and we're assuming coders do all their own work now? See http://git-scm.com/book/en/Distributed-Git-Distributed-Workflows. You don't need a gatekeeper our lieutenants or a benevolent (albeit cranky and foul mouthed) dictator for your project, it just depends on the scope and scale of what you're doing. I would consider it a strong smell if your organization has someone dedicated to merging code.
|
# ? Dec 29, 2013 01:17 |
|
Excuse me while I rag on second-system C++ for a moment:http://www.rust-lang.org/ posted:Rust is a curly-brace, block-structured expression language.
|
# ? Dec 29, 2013 01:31 |
|
That does seem to be the single most important factor in picking a language for a lot of programmers.
|
# ? Dec 29, 2013 01:32 |
|
nielsm posted:Atlassian SourceTree is pretty good. It's not perfect, and you will have to go command-line for some things, but it certainly helped me understand git better, and I think it gives a quite clear overview of what's actually happening in the repository. This reminded me that now that I'm back on Windows as my main OS, I finally want to try out SourceTree. Then I realize I still do all my development on a linux VM. :/ I guess I could share my development folder on the VM with the Windows host, but that seems like it might be an invitation for some disaster...but I'm not sure about that.
|
# ? Dec 29, 2013 01:36 |
|
Strong Sauce posted:What is the difference between what you do versus say: git rebase origin/master (obviously assuming origin/master is what you're trying to rebase on top of)? The difference is the alias will automatically pick the correct parent branch to rebase against. Removes the need to remember what you branched off of. Braaam posted:
I so wish this was more common. I try to hammer it into my coworkers (given a few "lightning" talks during some of our lunch-n-learns and other internal meetings) but it never works. And it's bit us in the rear end with several bisects when I get to go "see if we had all been rebasing this would have been easy". Still no dice.
|
# ? Dec 29, 2013 01:50 |
|
necrotic posted:The difference is the alias will automatically pick the correct parent branch to rebase against. Removes the need to remember what you branched off of. No, that's not true. The command that he gave will just allow you to make edits to the string of changes you've to the current working branch (edit, squash, delete), but will keep the same merge-base. Just doing a rebase on master will actually rebase the commits. If you have: pre:D F | | C E |/ B | A pre:D | C G |/ B | A pre:G | D | C | B | A
|
# ? Dec 29, 2013 02:07 |
|
Mustach posted:Excuse me while I rag on second-system C++ for a moment: It's a bunch of ML'ers going "Look, we even put in the loving braces, please give us a chance, all you mainstream programmers".
|
# ? Dec 29, 2013 02:15 |
|
Regarding git GUIs: I've been using Tortoisegit for a while now, and it seems pretty good to me. Sure, it doesn't really integrate with an IDE, but neither do the command line tools.
|
# ? Dec 29, 2013 02:29 |
|
Brain Candy posted:That might be true if that were what happened. Instead, we have somebody seriously stressing about giving good info based on completely reasonable but wrong assumptions. This is the definition of "poo poo happens". quote:I feel responsible not because I physically typed the command but because this guy knows nothing about git and would have typed anything I told him to (despite the fact that he's been "using" git for years and I just started learning it a year ago). I used to just do SA work and while it was our policy that we wouldn't guarantee any data that wasn't on a network drive but I'd still at least say "hey, sorry I lost your stuff" if I deleted someone's improperly-stored work. I mean you don't need to grovel on your hands and knees or anything but come on.
|
# ? Dec 29, 2013 03:22 |
|
Steve French posted:stuff about rebase Err, yeah. For some reason I thought merge-based worked differently.
|
# ? Dec 29, 2013 04:22 |
|
Yeah I'm definitely gonna have a frank discussion with the guy and say "look, here's what I think happened, I'm really sorry, let's work together to fix it and make sure this doesn't happen again." I don't think I could live with myself otherwise. Thanks for the advice guys. It helps that a glimmer of hope occurred to me this morning. There may be a WAR file on our staging server with his changes on it. I doubt I could be so lucky that he exported it with source but if we can get the JSPs and JavaScript out of it at least that's something. On the subject of git GUIs, I'm of the belief that they can be helpful to visualize the branches and the overall change history but none of them really expose the full power of git. If you don't learn the commands you haven't learned git. I think that was part of the problem here. All of our other team members use a GUI exclusively and don't know how to do much besides push and pull. They don't understand stashing, they don't understand branching, and so it's really no surprise that they only understand the necessity of committing in terms of being able to push to the remote so the build machine can churn out a WAR.
|
# ? Dec 29, 2013 15:30 |
|
Mustach posted:Excuse me while I rag on second-system C++ for a moment: You're joking, but the biggest reason I don't use Rust is because its if statement syntax has braces but not parentheses. I just can't handle that.
|
# ? Dec 29, 2013 17:37 |
|
There's nothing stopping you from adding parentheses, right?
|
# ? Dec 29, 2013 17:44 |
|
Mustach posted:Excuse me while I rag on second-system C++ for a moment: Considering how many times I've seen people express unwillingness to use {Inform 7, Scheme, Lua, Python} because it doesn't have curly braces (and is thus either "too different from what they're used to" or "clearly not a real programming language"), I'm not sure I blame them. There seems to be a depressingly large population of purported programmers who use the presence or absence of curly braces as the deciding factor in whether to check out a language or not. (On the other hand, do you really want those people using your language and thus posting on your mailing list and bug tracker and visiting your IRC channel?)
|
# ? Dec 29, 2013 17:44 |
|
Telling people that it's a curly-brace language is reasonable and informative, it's not just the fact that curly braces are used but it also communicates the sort of coding style and control flow the language uses, with statements and loops and conditionals, how variables come into scope and how long they stay in scope, and that it's not some big departure into functional programming la-la land.
|
# ? Dec 29, 2013 17:49 |
|
Perhaps I'm a little biased here but why not just let people choose? Why force yourself to be on one side or the other of a polarising issue?code:
e: shrughes posted:it's a curly-brace language [...] it's not some big departure into functional programming la-la land. gonadic io fucked around with this message at 19:51 on Dec 29, 2013 |
# ? Dec 29, 2013 17:59 |
|
shrughes posted:Telling people that it's a curly-brace language is reasonable and informative, it's not just the fact that curly braces are used but it also communicates the sort of coding style and control flow the language uses, with statements and loops and conditionals, how variables come into scope and how long they stay in scope, and that it's not some big departure into functional programming la-la land.
|
# ? Dec 29, 2013 19:34 |
|
A friend of mine got some source code from the outsourced team. The .git folder was included. This is the entire commit log for the master branch of this 180 hour project: code:
|
# ? Dec 29, 2013 19:53 |
|
Eleeleth posted:A friend of mine got some source code from the outsourced team. The .git folder was included. This is the entire commit log for the master branch of this 180 hour project: It's possible they were using some other form of source control and only periodically synched everything with your Git repo.
|
# ? Dec 29, 2013 19:55 |
|
Is the MAC@MACMINI.local real or is that anonymized?
|
# ? Dec 29, 2013 19:56 |
|
|
# ? May 29, 2024 19:23 |
|
shrughes posted:Is the MAC@MACMINI.local real or is that anonymized? That bit's real, and git was their only form of source control.
|
# ? Dec 29, 2013 19:57 |