|
Monkeyseesaw posted:This may be unpopular but I think git is a bit of a coding horror in the fact that it fails to really hide any details of its implementation and makes source control more complicated than it should be. I really didn't grok git until I realized my branches were pointers and my commits were nodes in a graph. I've never had to understand the internals of any source control system like that before. I'm confused, you think Git is a coding horror because it doesn't support the Subversion mental model?
|
# ? Sep 6, 2013 21:17 |
|
|
# ? Jun 1, 2024 04:31 |
|
No, he thinks Git is a coding horror because it fails to abstract away enough of the problem space. I'm inclined to agree, which is why I prefer Mercurial.
|
# ? Sep 6, 2013 21:27 |
|
Monkeyseesaw posted:This may be unpopular but I think git is a bit of a coding horror in the fact that it fails to really hide any details of its implementation and makes source control more complicated than it should be. I really didn't grok git until I realized my branches were pointers and my commits were nodes in a graph. I've never had to understand the internals of any source control system like that before. I agree... it seems like it's way more difficult than it should be to effectively use Git.
|
# ? Sep 6, 2013 21:27 |
|
Got to ask this question today. "Wait, are those references to user-defined fields hard coded into the system?" "...yes." The person who originally wrote the file was relying on the fields that the end user could change at will always representing very specific data.
|
# ? Sep 6, 2013 21:58 |
|
Monkeyseesaw posted:This may be unpopular but I think git is a bit of a coding horror in the fact that it fails to really hide any details of its implementation and makes source control more complicated than it should be. I really didn't grok git until I realized my branches were pointers and my commits were nodes in a graph. I've never had to understand the internals of any source control system like that before. This is why, I continue to believe there's an opportunity for a killer git UI out there. It doesn't exist yet, but there are several okay ones like Github's clients, and Sourcetree.
|
# ? Sep 6, 2013 22:11 |
|
The last time I used SourceTree, I think it outright told me to drop to the command line to do something or the other.Monkeyseesaw posted:my branches were pointers and my commits were nodes in a graph IDK why but the first thing that popped into my head after reading that was
|
# ? Sep 6, 2013 22:11 |
|
Factor Mystic posted:This is why, I continue to believe there's an opportunity for a killer git UI out there. It doesn't exist yet, but there are several okay ones like Github's clients, and Sourcetree. TortoiseGit's pretty good, but it's sadly windows only... On topic: yesterday I witnessed some old legacy code that did 3 full table scans (of the same table), joined it to itself, stored the resulting table in another table, then did 3 or 4 checks around some input, before finally inserting the user-inputted data back into the first table. Thankfully, the person who wrote this monstrosity was fired a long time before I got here, but this isn't the first time I've come across some awful code, that, when history checked via Git, points entirely to them.
|
# ? Sep 6, 2013 22:30 |
|
I'm not sure that git is a horror for presenting a low-level view of the world, especially if some people want that. It's certainly not a tool that's designed for anybody but programmers, that's for sure. Everybody has their own quirky ways of managing their source code that it's hard to accommodate everybody. If there's one thing I'd like to fix up about git's UI, it's all the tiny inconsistencies in its command line UI. How do you delete something? git branch -d foo, git remote rm foo. For a while I was thinking of writing a new command line client around libgit2 that fixed all of this. As for a more visual UI, it's not the best thing in the world, but I manage to work effectively inside magit. It's a fairly decent way of staging only some hunks of a file or things like that.
|
# ? Sep 6, 2013 22:46 |
|
To say git's CLI is "a bit" of a horror is an understatement. If somebody built an alternative UI I'd be all over that in a second -- and I'm sure lots of other people would be too. Right now I just alias everything to things that make sense. Even still, some things are critically wrong with git (or, in other words, critically right with Mercurial.) Plugin and extension architecture to name one. Extending git is a total mess. xtal fucked around with this message at 23:07 on Sep 6, 2013 |
# ? Sep 6, 2013 23:05 |
|
The only reason I stuck with git over hg over the years was because I've always really liked github.
|
# ? Sep 6, 2013 23:15 |
|
Can anyone comment on how bitbucket compares to git nowadays?
|
# ? Sep 6, 2013 23:24 |
|
Hard NOP Life posted:Can anyone comment on how bitbucket compares to git nowadays? Nope.
|
# ? Sep 6, 2013 23:31 |
|
No one attacks Bitbucket so mirror your github repos there just in case.
|
# ? Sep 6, 2013 23:33 |
|
Hard NOP Life posted:Can anyone comment on how bitbucket compares to git nowadays? GitHub is far superior to BitBucket. The margin between the two is only getting bigger. Posting Principle posted:No one attacks Bitbucket so mirror your github repos there just in case. I recently set up a VPS that I store my repos on, which asynchronously syncs to GitHub. It's loads faster connecting to a VPS in the same city as me, and I'm protected if GitHub goes down or they decide to delete my repository because somebody didn't like it. Highly recommended and easy to set up. xtal fucked around with this message at 00:09 on Sep 7, 2013 |
# ? Sep 6, 2013 23:52 |
|
xtal posted:To say git's CLI is "a bit" of a horror is an understatement. If somebody built an alternative UI I'd be all over that in a second -- and I'm sure lots of other people would be too. Right now I just alias everything to things that make sense. I haven't used it but for what it's worth, there is Legit for an alternative git CLI.
|
# ? Sep 7, 2013 00:27 |
|
Thermopyle posted:The only reason I stuck with git over hg over the years was because I've always really liked github.
|
# ? Sep 7, 2013 00:55 |
|
xtal posted:Extending git is a total mess. That's why git gives you access to its lower lever workings. Almost any reasonable addition can be formed from a suitable composition of git's pre-provided tools. What is wrong with giving you the same tools that are used by git itself?
|
# ? Sep 7, 2013 03:02 |
|
xtal posted:GitHub is far superior to BitBucket. The margin between the two is only getting bigger. I'm a heavy Github user but I had to use Bitbucket earlier this year to hand off a project at an old job (needed a free private repo). My biggest complaint was the way that teams are managed. Is there any good reason for a team to also be a user account (instead of just a way of grouping other users) with its own unique e-mail address? it caused a huge pain when I first tried setting all the organizational stuff up, mainly because there wasn't an obvious e-mail to associate with the team that wasn't already one of the members'.
|
# ? Sep 7, 2013 03:51 |
|
100% BitBucket user here, not because it's better, but because our company's budget is close to $0. The UI is pretty atrocious, especially when you have over a few dozen repositories in it and names get long. I'd use GitHub if they were free for private repos. BitBucket however seems just fine if you never use the website and you just care about having somewhere safe to dump your code. Again, having paid them a total of $0 over years, I'm in no position to complain about anything.
|
# ? Sep 7, 2013 04:34 |
|
In a file called reportTemplateDynamicLibrary.php, formatted exactly as you see here: What the hell does this even do? php:<? function clean_driving($driving){ if(empty($driving)) return""; $driving = trim($driving); $driving = substr($driving,strlen($driving)-1) =="," ? substr($driving,0,-1): $driving; $driving =str_replace(",",",\n\t",$driving); return "$driving,\n"; } ?> php:<? function output_line(){ global $schema, $last_invoice_row,$comma_pipe,$table_storage,$report_type,$library; foreach($schema as $fields => $attributes){ $lookup = strtolower($fields); extract($attributes); $value = (isset($last_invoice_row[$lookup]) ? $last_invoice_row[$lookup] : ($table ==''? $field : ((strstr($format,"varchar") || strstr($format,"date")) ? "" : "0.00" ) ) ); $value = is_array($value) ? $value[$report_type] : $value; $output .=$value.$comma_pipe; } insert_storage($output); echo substr($output,0,-1)."\n"; return; } ?> php:<? if($comma_pipe =="|") print_footer(); ?> php:<? function round1 ($string) { return round($string,1); } function round2 ($string) { return round($string,2); } function round3 ($string) { setlocale(LC_MONETARY, 'en_US'); return money_format('%.3n', $string); } function round4 ($string) { setlocale(LC_MONETARY, 'en_US'); return money_format('%.4n', $string); } function round5 ($string) { setlocale(LC_MONETARY, 'en_US'); return money_format('%.5n', $string); } ?>
|
# ? Sep 7, 2013 04:45 |
|
Sinestro posted:Using ClearCase is like volunteering to get mugged so you can then have a icepick jammed in your eye socket. And then the entire city is leveled by a nuclear explosion, instantly incinerating your lifeless husk of a body. I can't decide if the fat client "NFS share masquerading as a repo using flaky custom NFS drivers" or CCRC "gently caress your loving discordance detected fucker" is worse. What I can say is if you ever wanted to apply C's manual header and #include management to your source control system, config specs are right up your alley. I am trying to check in about 5000 updated files for a fairly big upgrade of a third party library right now. I have been doing this for over a week now and it still isn't done. If I try to do too many at once, java consumes 1.2GB of memory, hits the 32-bit limit, and dies. It takes about 4-6 seconds per file, not including other overhead. No one else can touch that branch because commits aren't done as a transaction so the whole thing is hosed until I'm done. That also includes merges so using separate branches doesn't help. Mercurial or git could have done it in two minutes. gently caress.
|
# ? Sep 7, 2013 05:01 |
|
Ender.uNF posted:And then the entire city is leveled by a nuclear explosion, instantly incinerating your lifeless husk of a body. https://github.com/charleso/git-cc helpful?
|
# ? Sep 7, 2013 05:24 |
|
Vasja posted:What is a commapipe?
|
# ? Sep 7, 2013 05:29 |
|
Sinestro posted:That's why git gives you access to its lower lever workings. Almost any reasonable addition can be formed from a suitable composition of git's pre-provided tools. What is wrong with giving you the same tools that are used by git itself? Mercurial does too, but with a sane API. Extending git is done with a collection of bash scripts and aliases. Its hooks/events functionality is also a lot worse.
|
# ? Sep 7, 2013 06:19 |
|
I really don't understand why anyone would find git harder to use than any other VCS or DVCS. Like, what are you guys doing? Cloning, merging, forking, pulling, cherry-picking, and blaming are dead simple. And all git UIs suck save for Github/Bitbucket because a simple alias is nicer than a totally different UX workflow. Even github talks about a bunch of features it has available but find difficult to expose through the UI.
|
# ? Sep 7, 2013 06:49 |
|
Rainbow Pony Deluxe posted:I really don't understand why anyone would find git harder to use than any other VCS or DVCS. Like, what are you guys doing? Cloning, merging, forking, pulling, cherry-picking, and blaming are dead simple. And all git UIs suck save for Github/Bitbucket because a simple alias is nicer than a totally different UX workflow. Even github talks about a bunch of features it has available but find difficult to expose through the UI. It's because the UI is an inconsistent clusterfuck, basically. Some commands use foo add and foo rm, some use bar -a and bar -d. Checkout and reset do at least three different things each - and both of them are what other VCSs call revert, depending on how you use them, while git revert is everything else rollback. Pull looks like what you want but you probably wanted fetch+merge instead and now you're confused because your remote tracking branches don't seem to have the right head commits. I do like git and use it every day, but the UI is inconsistent with both other version control systems and with itself, and its design as a huge pile of bash, perl and python scripts with no proper API means that writing frontends for it or other programs that communicate with it is way harder than it should be.
|
# ? Sep 7, 2013 15:28 |
|
It emits some pretty hilarious errors sometimes too:code:
|
# ? Sep 7, 2013 16:14 |
|
The best kind of error handling is when you detect enough context to know exactly what the user wanted to do, but you still just don't do it.
|
# ? Sep 7, 2013 16:21 |
|
code:
|
# ? Sep 7, 2013 16:40 |
|
I don't think I can post the code but I recently reverse-engineered an encrypted file format where each byte is encrypted by switching the nibbles and XORing with a constant value. If an algorithm was good enough for Julius Caesar, then by God it's good enough for us! poopgiggle fucked around with this message at 17:02 on Sep 7, 2013 |
# ? Sep 7, 2013 16:51 |
|
Flobbster posted:The best kind of error handling is when you detect enough context to know exactly what the user wanted to do, but you still just don't do it. Command line processing can be enough of a pain in the rear end. Why add context guessing heuristics to the mix? I can only see that ending in madness.
|
# ? Sep 7, 2013 16:56 |
|
code:
|
# ? Sep 7, 2013 19:11 |
|
ToxicFrog posted:
That's beautifully stupid.
|
# ? Sep 7, 2013 19:20 |
|
Mercurial subrepos are so much better than Git submodules. Submodules can go to hell.
|
# ? Sep 7, 2013 19:26 |
|
Captain Capacitor posted:Mercurial subrepos are so much better than Git submodules. In fairness they're both really terrible.
|
# ? Sep 7, 2013 19:28 |
|
ToxicFrog posted:
Can we award this entry some sort of prize? Are we fresh out of blue ribbons?
|
# ? Sep 7, 2013 20:09 |
|
poopgiggle posted:I don't think I can post the code but I recently reverse-engineered an encrypted file format where each byte is encrypted by switching the nibbles and XORing with a constant value.
|
# ? Sep 7, 2013 20:15 |
|
code:
|
# ? Sep 7, 2013 20:25 |
|
Internet Janitor posted:
This doubtless seems bizarre when you first encounter it, but there is a reason it does that, and it has to do with the Python designers' efforts to keep to a clean and consistent design. "exit" is not a keyword in the language, rather it's a callable object (a kind of function, if you like) that has its string representation overloaded to produce that message. That is why that message prints when you enter its name as an expression statement in the command-line interface. Of course they could instead make it an additional keyword for the command-line interface only, but that's messy. And they can't really cause evaluation of its string representation to make the interpreter exit, because well, I shouldn't have to explain why that would be a bad idea. See: code:
|
# ? Sep 7, 2013 20:25 |
|
|
# ? Jun 1, 2024 04:31 |
|
Hammerite posted:This doubtless seems bizarre when you first encounter it, but there is a reason it does that, and it has to do with the Python designers' efforts to keep to a clean and consistent design. "exit" is not a keyword in the language, rather it's a callable object (a kind of function, if you like) that has its string representation overloaded to produce that message. That is why that message prints when you enter its name as an expression statement in the command-line interface. Of course they could instead make it an additional keyword for the command-line interface only, but that's messy. And they can't really cause evaluation of its string representation to make the interpreter exit, because well, I shouldn't have to explain why that would be a bad idea. See: Well, thank you for explaining what's going on, but I still don't buy that it's a good idea. Let "exit" be a keyword that exits the interpreter immediately, perhaps with a "goodbye!" message for clarity.
|
# ? Sep 7, 2013 20:31 |