News for hackers. Stuff that matters.
Re:Oh shit, git: Getting myself out of bad situations by swalsh on Monday December 18, 2017 @11:21AM (#15952709)
I use the git CLI. I do it for one reason. I know exactly what i'm doing on it. I have nothing to prove to anyone, I'm not trying to impress anyone with my "hacker" skillz.

When I've tried GUI's, I'm not 100% sure what's going on under the covers. Sometimes they try to obfuscate things. While I'm probably not the worlds most advanced user, I know enough to know what I want to do, and how to do it. The CLI let's me do it. The GUI get's in my way.

Re:Oh shit, git: Getting myself out of bad situations by dilap on Monday December 18, 2017 @12:02PM (#15953107)
It's not anything inherent to a visual UI though, it's just that most of the UIs that exist are trying to put their own model on top of git, rather than embracing git's model.

The one exception to this I've found is GitUp (mac only, sadly), and it's excellent. It's whole model is, "what operations can I perform on this graph," which is exactly the model git has. It's great.

Re:Oh shit, git: Getting myself out of bad situations by dasil003 on Monday December 18, 2017 @12:49PM (#15953554)
I think you've put your finger on the schism of why so many git users prefer a GUI. The built-in porcelain is stupidly inconsistent and confusing. And yet, git's underlying model is so simple and powerful that I think it's worth suffering the bad CLI just to be more fluent and able to utilize git's power fully. The model itself is very easy to grok, it just takes some time to memorize the various random incantations and occasionally look something up, but I don't consider that a big deal for a core tool I use every day.
Re:Oh shit, git: Getting myself out of bad situations by euske on Monday December 18, 2017 @11:34PM (#15957787)
"C language is so simple and powerful that I think it's worth suffering the bad syntax and memory leak just to be more fluent and be able to utilize the machine's power fully."

Pick the right tool for the right job, man.

Joking aside, think about the ratio of tasks. Most of the git commands I do is deadly simple. There might be once-in-a-year complex tasks that are more suitable to CLI, but for 99% of the tasks I think GUI could have a net gain in total. Although I'm not a GUI user in this particular case, I'd advocate to use whatever most intuitive to you when possible.

Disclaimer: I don't think C syntax is that bad.

Re:Oh shit, git: Getting myself out of bad situations by earenndil on Thursday December 21, 2017 @12:41AM (#15976704)
It seems like the other way around to me. For 99% of simple tasks, the cli is quick and easy. There are a couple of simple commands, I know and remember them. For the once-a-year complex tasks, maybe I need the gui to be able to more easily and quickly accomplish them.
Re:Oh shit, git: Getting myself out of bad situations by chiefalchemist on Monday December 18, 2017 @05:14PM (#15956000)
It might not feelblike that big of a deal, but certainly there has got to be on any given day far more important things you can use those brain cycles for, yes? Low friction or not it's still friction. Friction that can be removed. Yet so many refuse to do so. There's something wrong with this this-is-how-we've-always-do-it picture.
Re:Oh shit, git: Getting myself out of bad situations by dasil003 on Monday December 18, 2017 @06:14PM (#15956331)
You make it sound like tradition or a cargo cult—it's not. Git is fundamentally better than most of the alternatives, but in my opinion it's misguided to try to slap a better interface over the warts. Rewriting the porcelain would be good, but I don't think it's personally worth investing in until someone makes an attempt that's good enough to get traction and significant mindshare. In the meantime I've already made the investment in learning git and it pretty much stays out of my way.
Re:Oh shit, git: Getting myself out of bad situations by chiefalchemist on Monday December 18, 2017 @10:45PM (#15957569)
Not to sound snarky / adversarial but why is it that (nearly) every article I see on Git has some sort of diagram within it? Yet "execution" is typically limited to CLI? That just feels suboptimal, if not just foolish.
Re:Oh shit, git: Getting myself out of bad situations by geezerjay on Tuesday December 19, 2017 @03:58AM (#15958760)
> Yet "execution" is typically limited to CLI? That just feels suboptimal, if not just foolish.

It looks like you mindlessly associate a CLI with a poor -- or suboptimal -- user experience. In fact even your choice of weasel words conveys the idea that you want to mindlessly push an irrational belief in spite of not being able to provide arguments to support it. The truth of the matter is that git -- or any other VCS -- operated through commands that change the current state of the repo. The command line interface excels when the user wants to run commands. Any GUI developed for command line tool will end up doing nothing more than replicate what the CLI already does, and will do so poorly.

Re:Oh shit, git: Getting myself out of bad situations by chiefalchemist on Wednesday December 20, 2017 @07:06PM (#15975125)
Not really. I associate a picture with 1000 words. So if the detailed example/ explanation is an image why isn't the actual process(es) a reflection of that?

Put another way, Git is a process that can be rendered pictorially. Words (i.e., CLI) are a less intuitive abstraction.

Pardon me for stating the obvious :)

Re:Oh shit, git: Getting myself out of bad situations by chris_wot on Tuesday December 19, 2017 @12:07AM (#15957904)
The issue is with understanding staging and the working directory. The lightbulb moment for me was reading this article from Atlassian:

https://www.atlassian.com/git/tutorials/resetting-checking-o...

Understanding that git reset --soft moves HEAD but doesn't change the staged snapshot or working directory, whilst --mixed updates the staged snapshot to match the commit but doesn't touch the working directory was very useful. And knowing that reset --hard updates both staging and the working directory to the commit was where I suddenly "got it".

Re:Oh shit, git: Getting myself out of bad situations by chiefalchemist on Wednesday December 20, 2017 @07:08PM (#15975142)
Right. And notice all the diagrams. So why use words when pictures better reflect reality?
Re:Oh shit, git: Getting myself out of bad situations by nothrabannosir on Monday December 18, 2017 @07:55PM (#15956914)
> Git is fundamentally better than most of the alternatives

No way. Only if you define “good” as “good at the kind of project that git is good at,” where it will hold vacuously.

I suffer daily through the cyst that is git LFS, and it’s a joke. It would be funny if it weren’t so tragic. I hear that it’s not doing any better in large scale mono repo land. Google doesn’t use it, afaik. Microsoft does (but multi repo, last I heard), Facebook doesn’t (custom Mercurial, some tasty quotes at [0]). Not a glowing “fundamentally better”, exactly.

[0] https://code.facebook.com/posts/218678814984400/scaling-merc...

Re:Oh shit, git: Getting myself out of bad situations by dasil003 on Tuesday December 19, 2017 @12:41AM (#15958049)
That's a fair criticism for sure, git makes tradeoffs that fall apart with large repos. You can, however, go a whole career without those things being a problem. Most code repositories are simply not that big.
Re:Oh shit, git: Getting myself out of bad situations by jbergens on Thursday December 21, 2017 @09:16AM (#15978847)
And you can go a whole career without needing the extra staging features that git has and some other systems like mercurial don't. The ui gets a lot easier without that and for many developers that is probably the best trade off.
Re:Oh shit, git: Getting myself out of bad situations by rhencke on Monday December 18, 2017 @09:22PM (#15957251)
1. Git LFS is not part of Git. It's an unofficial extension, despite the name. I've got my own qualms about Git, but that's like complaining about GitHub's forking model as a reason Git is bad.

2. Microsoft uses Git in single large-scale mono repo form, for - believe it or not - Windows. It clocks in at about 3.5 million files, and a full clone weighs in at 300GB:

https://blogs.msdn.microsoft.com/bharry/2017/05/24/the-large...

Re:Oh shit, git: Getting myself out of bad situations by piyush_soni on Tuesday December 19, 2017 @12:05AM (#15957902)
Microsoft uses Git in single large-scale mono repo form

They had to change git itself to be able to do that. So no, the article itself shows it was not ready for that big a repository.

Re:Oh shit, git: Getting myself out of bad situations by nothrabannosir on Tuesday December 19, 2017 @04:30AM (#15958935)
Git LFS is not part of Git.

That’s my point: without LFS it’s even worse to work with large files. If LFS is the best option you have, forget it. That’s an entire area of projects (anything with assets) you can’t use Git for.

Re:Oh shit, git: Getting myself out of bad situations by dilap on Monday December 18, 2017 @08:46PM (#15957114)
I believe MS has most of windows in a git mono-repo now, enabled by a custom git-supporting filesystem they've developed:

https://github.com/Microsoft/GVFS

Pretty cool stuff. Doesn't seem to address the large-files case so much as the many-files case, though. I would love better git support for large files.

Re:Oh shit, git: Getting myself out of bad situations by u801e on Monday December 18, 2017 @07:04PM (#15956660)
> The built-in porcelain is stupidly inconsistent and confusing.

That's why I end up using the plumbing commands to do things that porcelain commands don't let me do directly. For example, I'll use git diff along with git apply and recountdiff (from the patchutils package) to stage individual hunks or edit hunks prior to staging.

Re:Oh shit, git: Getting myself out of bad situations by mikedelfino on Monday December 18, 2017 @05:49PM (#15956204)
One could also setup aliases for some of the incantations. I personally have `git uncommit` aliased to the proper command line that I never remember.
Re:Oh shit, git: Getting myself out of bad situations by donarb on Monday December 18, 2017 @07:30PM (#15956774)
I use aliases for the most common commands, gs, gd, gb, gco, ga, gc. You can guess what those do.
Re:Oh shit, git: Getting myself out of bad situations by geezerjay on Tuesday December 19, 2017 @03:48AM (#15958714)
The way you confuse git porcelain with git CLI makes it quite clear that you know nothing about either. I'm yet to find a GUI for any VCS that comes close to doing a job as good as any CLI.
Re:Oh shit, git: Getting myself out of bad situations by dasil003 on Tuesday December 19, 2017 @12:44PM (#15962070)
One way to make yourself feel superior to others is to adopt a level of pedantry that only you yourself can meet your own standard. If you then assume everyone around you is ignorant you are not as smart as you think.

git porcelain is a CLI. I am well aware that it is only a subset of git's CLI.

Re:Oh shit, git: Getting myself out of bad situations by giancarlostoro on Monday December 18, 2017 @01:39PM (#15954041)
SourceTree keeps the same language regular git uses. But I highly agree. JetBrains IDEs add their own lingo out of support for multiple version control plugins I'm sure but its confusing and easy to screw up. SourceTree is the one GUI client I want on Linux...
Re:Oh shit, git: Getting myself out of bad situations by murukesh_s on Monday December 18, 2017 @09:50PM (#15957354)
This is one time when we wish source tree was written in electron!
Re:Oh shit, git: Getting myself out of bad situations by ythn on Monday December 18, 2017 @04:42PM (#15955774)
VSCode is the only Git GUI that you need and it's available on Linux
Re:Oh shit, git: Getting myself out of bad situations by Drdrdrq on Monday December 18, 2017 @04:54PM (#15955863)
Do you use it? I have it enabled, but when I tried to revert a few lines (which should be the simplest operation ever - NetBeans did it perfectly; may it rest in peace...) I got some horrific message that made me doubt what the operation will do. So I haven't gathered enough courage to try committing anything... With CLI at least I know what I did wrong.
Re:Oh shit, git: Getting myself out of bad situations by giancarlostoro on Wednesday December 20, 2017 @12:34AM (#15967272)
VSCode doesn't consistently use git's language afaik, I could be wrong though.
Re:Oh shit, git: Getting myself out of bad situations by Groxx on Monday December 18, 2017 @06:21PM (#15956367)
http://gitup.co/

This looks fantastic, thanks for mentioning it! I've been looking for a GUI that doesn't mesh poorly with [whatever patterns my team uses] / without always pushing other features or a signup.

Re:Oh shit, git: Getting myself out of bad situations by benliong78 on Monday December 18, 2017 @11:58PM (#15957878)
Thanks for the recommendation. Fantastic looking software that provides a far better visualization of the repo than anything else I have used. Bravo.

I use CLI for almost everything but sometimes it helps to have a visual representation of the repo.

Re:Oh shit, git: Getting myself out of bad situations by dilap on Monday December 18, 2017 @08:51PM (#15957134)
It's a really sweet piece of software, and I'm surprised it's not more popular. I'd be curious to hear how it ends up going for ya'll -- you can message me on twitter at @hazememry if you'd like.
Re:Oh shit, git: Getting myself out of bad situations by Groxx on Monday December 18, 2017 @10:26PM (#15957490)
So far I've found:

    it's reasonably fast until I throw it at a huge monorepo :)  but it still works (~2fps)!  even `gitk` errors on this one.
    missing some hotkeys (like prev/next commit buttons in preview)
    freezes on remote-repo actions like fetch/pull/etc.  likely due to our enterprisey ssh setup.
    generally missing a bit of polish.  click targets are small, could use some more config (and only in one location, "search commits" is in its own thing), etc
Aside from the remote repo freeze-up, I'm liking it a lot. Way better control than others I've tried (i.e. it has nearly all the features), undo support, and a much better mental-model for Git in general.

If I can figure out how to fix the remote freeze-up, it might become my daily driver, which would be a first for a Git GUI.

Re:Oh shit, git: Getting myself out of bad situations by dilap on Tuesday December 19, 2017 @12:00PM (#15961603)
Yep, doesn't scale great to huge repos, sadly.

I hadn't thought about the prev/next preview missing hotkeys, but you're right. I realized what I do is go into preview with space, leave preview with space, and then use the arrow keys to select the next commit I'm interested in. So in effect, "space, down, space" is hotkey for next commit.

Bummer about the remote freeze thing. I think the dev is reasonably responsive to bug reports.

I've got a list of things myself I think could be better, but I've been too lazy to attempt any of them. But I do try to proselytize in the hopes it'll pick up a bigger community. :-)

Re:Oh shit, git: Getting myself out of bad situations by piyush_soni on Tuesday December 19, 2017 @12:09AM (#15957918)
I thought it's nice too, and just downloaded it to find out it's Mac only.
Re:Oh shit, git: Getting myself out of bad situations by dilap on Tuesday December 19, 2017 @10:32AM (#15960846)
Yep :(
Re:Oh shit, git: Getting myself out of bad situations by hyperpallium on Monday December 18, 2017 @09:48PM (#15957345)
I'd thought a programming language, for manipulating data structures, would work well... but when I had a go at it, it wasn't as easy to use as I thought. It's because the typical usage patterns aren't simple.

A gui with drag-and-drop to rebase a graph also seems like it would work well...

Re:Oh shit, git: Getting myself out of bad situations by thomasahle on Monday December 18, 2017 @07:20PM (#15956725)
I was in the cli only camp, but I just looked at GitUp and that actually looks really useful!
Re:Oh shit, git: Getting myself out of bad situations by aldanor on Monday December 18, 2017 @12:02PM (#15953106)
There are GUIs that are very close to CLI that don't try to reinvent a wheel and instead just map directly to what git does.

The best one, I think, being Magit for Emacs (if you can call that a 'GUI' given you can run it in the terminal).

If you get used to commit things by-line instead of by-file (which is generally highly recommended with git), and also clean up your history/squash things a lot, using git cli gets VERY tedious very fast; I'd rather do it in several keypresses because why not.

Re:Oh shit, git: Getting myself out of bad situations by dilap on Monday December 18, 2017 @12:05PM (#15953128)
Sort of off-topic, but magit isn't really GUI :-) -- though it is very nice, if you're an emacs user. It's Achilles' heel is speed, though -- too damn slow. (Last time I tried it, anyway, which was a while ago.)
Re:Oh shit, git: Getting myself out of bad situations by tarsius on Monday December 18, 2017 @12:41PM (#15953483)
I think Magit could be classified as a TUI [1].

But that still doesn't help explain its benefits to someone who hasn't tried it. For the crowdfunding campaign that I ran earlier this year I wrote a few articles. For those unfamiliar with Magit I would recommend [2] and the more visual [3].

[1] https://en.wikipedia.org/wiki/Text-based_user_interface [2] https://emacsair.me/2017/09/01/the-magical-git-interface/#st... [3] https://emacsair.me/2017/09/01/magit-walk-through/#start

Re:Oh shit, git: Getting myself out of bad situations by aldanor on Monday December 18, 2017 @12:09PM (#15953164)
Well. That depends :) I don't develop in Emacs and use it solely for hosting Magit, in a separate window. So it's kind of a GUI I guess; more so than a CLI anyway.

> It's Achilles' heel is speed, though -- too damn slow. (Last time I tried it, anyway, which was a while ago.)

Don't remember a single of case of it feeling too slow in the last few years, whether on linux/mac... (maybe it just got better over time though)

Re:Oh shit, git: Getting myself out of bad situations by dilap on Monday December 18, 2017 @12:22PM (#15953304)
interesting. i'm on mac; i'll have to give it another try. also we might just have different ideas of "too slow"; for common operations, anything more than instant is basically too slow. :-)
Re:Oh shit, git: Getting myself out of bad situations by tarsius on Monday December 18, 2017 @12:44PM (#15953517)
On macOS it helps to use Emacs 26.1 (unreleased but very solid) or to use a build with a backport of the vfork patch. For more information see https://magit.vc/manual/magit/MacOS-Performance.html.

I also plan to make Magit faster across all platforms.

Re:Oh shit, git: Getting myself out of bad situations by dilap on Monday December 18, 2017 @12:50PM (#15953565)
very cool to hear that performance is a focus area!
Re:Oh shit, git: Getting myself out of bad situations by JetSetWilly on Monday December 18, 2017 @12:11PM (#15953193)
It seems to be incredibly slow on windows, but fine on linux.

It seems like the sort of ui that needs to be near-instant in order to be usable, the premise being you can tap the various shortcuts to assemble a command very rapidly. But on windows this is an exercise in frustration because each command takes at least a second or two at best to execute and often much longer.

Re:Oh shit, git: Getting myself out of bad situations by thomastjeffery on Monday December 18, 2017 @03:18PM (#15955084)
It's a Graphical User Interface.

I think that the distinction that makes a Commnad Line Interface is the REPL.

I consider anything with a non-linear UI that you can see a GUI.

Re:Oh shit, git: Getting myself out of bad situations by jdc0589 on Monday December 18, 2017 @11:35PM (#15957791)
GitExtensions was/is solid too; very little abstraction, it was just built for speed/efficiency. Someone recently told me it runs on Mono too now, but I haven't used it in years and never outside of Windows.
Re:Oh shit, git: Getting myself out of bad situations by MonkeyIsNull on Monday December 18, 2017 @11:46AM (#15952963)
> I'm not 100% sure what's going on under the covers.

This. A thousand times over. I like to see exactly what git is doing and when; I don't want any magic stuff under the covers done for me.

Re:Oh shit, git: Getting myself out of bad situations by ninkendo on Monday December 18, 2017 @11:52AM (#15953013)
GitHub's GUI is the worst. It has a "sync" button.

As soon as I saw that button I knew I'd have trouble using it.. what will "sync" do? Push my branches? Pull tracking branches? Will merge commits get implicitly created? Or will it just fetch? From what servers? I didn't want to risk having my local master get pushed into production just because GH wants to make things easy for me, so I just quit it and went back to the CLI.

Re:Oh shit, git: Getting myself out of bad situations by mchahn on Monday December 18, 2017 @01:39PM (#15954045)
GitHub's Atom editor recently added git operations. I use Atom but haven't had the time to try the git wrapping. Has anyone else used it?
Re:Oh shit, git: Getting myself out of bad situations by emodendroket on Monday December 18, 2017 @12:15PM (#15953232)
It just pushes the current branch afaik.
Re:Oh shit, git: Getting myself out of bad situations by dotancohen on Monday December 18, 2017 @03:16PM (#15955064)
So they should just call it 'push'. The word 'sync' is not in the Git terminology.
Re:Oh shit, git: Getting myself out of bad situations by aalleavitch on Tuesday December 19, 2017 @02:10AM (#15958352)
In its defense, git terminology is stupid. It took me way too long to reason out what the fuck a pull request meant. To your starting developer it seems to indicate the opposite of what it does.
Re:Oh shit, git: Getting myself out of bad situations by emodendroket on Monday December 18, 2017 @08:03PM (#15956954)
The GitHub desktop client is very limited and seems mostly geared toward a lone developer or small team who has never used git before. In this context I think it's a reasonable decision to use a more common verb.
Re:Oh shit, git: Getting myself out of bad situations by craftyguy on Monday December 18, 2017 @10:49PM (#15957590)
Nope. That does no one any good. Using git verbage would, at the very least, acclimate them to very common terminology used by the rest of the folks they will eventually encounter.
Re:Oh shit, git: Getting myself out of bad situations by emodendroket on Tuesday December 19, 2017 @06:35AM (#15959422)
Well, I disagree, because the alternative for many is probably no source control.
Re:Oh shit, git: Getting myself out of bad situations by craftyguy on Tuesday December 19, 2017 @11:30PM (#15967061)
Folks writing production crap would opt for no source control? Well, fair enough I guess. But I (and probably most competent sw engineering folks) would never hire someone who was completely oblivious to using source control. So hopefully that 'practice' would die through attrition.
Re:Oh shit, git: Getting myself out of bad situations by emodendroket on Wednesday December 20, 2017 @11:11AM (#15970795)
You've got to meet people where they are. Someone who is familiar with how git works is going to find the git GUI client way too limiting to seriously consider using it, whatever verb they use for the push function.
Re:Oh shit, git: Getting myself out of bad situations by michaelmior on Monday December 18, 2017 @12:23PM (#15953314)
So it never pulls updates on the remote? That seems like pretty unexpected behaviour.
Re:Oh shit, git: Getting myself out of bad situations by emodendroket on Monday December 18, 2017 @12:35PM (#15953431)
It pulls and then pushes, I guess I should say, but I was considering "pulls and..." part of the push operation.
Re:Oh shit, git: Getting myself out of bad situations by pacoverdi on Monday December 18, 2017 @11:58AM (#15953058)
CLI and GUI are both user interfaces and magic is in the eye of the beholder: if you know your tools, you can predict what will happen under the hood when you click on a button as much as when you submit a command (it's not magic anymore).

Personally, I use the CLI and often have no idea what I'm doing ;)

Re:Oh shit, git: Getting myself out of bad situations by giancarlostoro on Monday December 18, 2017 @01:41PM (#15954066)
Even GUI based SQL tools show you a log of commands used... Git GUI clients don't even show you beforehand or after what the heck just happened... Sad.
Re:Oh shit, git: Getting myself out of bad situations by tigershark on Monday December 18, 2017 @02:43PM (#15954762)
It's definitely not true. I'm not sure what kind of gui did you use but both sourcetree and gitextensions show you the command log.
Re:Oh shit, git: Getting myself out of bad situations by giancarlostoro on Wednesday December 20, 2017 @12:33AM (#15967268)
Guess I was wrong, but I never noticed said log. I use SourceTree.
Re:Oh shit, git: Getting myself out of bad situations by WhyNotHugo on Monday December 18, 2017 @04:15PM (#15955589)
Same here. Regrettably, if you UNDERSTAND git, a GUI won't work for you. If you're interested in understanding it, it won't work for you either.

A GUI works fine if you want to get things done. If you like to know what goes on under the hood, it's just confuse you.

Re:Oh shit, git: Getting myself out of bad situations by electricEmu on Monday December 18, 2017 @05:50PM (#15956213)
I understand git quite well and use a GUI. I was interested in understanding it while using the git.

It's pretty sweet that GitExtensions displays the exact command executed. Actually, it made learning vastly easier for the people I taught after myself.

Some people do better with GUIs; others the CLI.

Re:Oh shit, git: Getting myself out of bad situations by bseow on Monday December 18, 2017 @06:52PM (#15956591)
I feel this has become a bit of a standard excuse for git. The reason I use a gui isn't because I don't know how git works (while I do forget that too from time to time), but because I can't remember the default behavior and notation of the git cli. I'd be perfectly happy if the cli was actually made to be "low level", but it to a large degree isn't. So if I'm going to have to remember what some abstraction does, it might as well be on a higher level.

One example of this is the table at the bottom of this page: https://git-scm.com/blog/2011/07/11/reset.html

Re:Oh shit, git: Getting myself out of bad situations by admax88q on Tuesday December 19, 2017 @01:39PM (#15962705)
The git CLI is horribly inconsistent.

http://stevelosh.com/blog/2013/04/git-koans/

Re:Oh shit, git: Getting myself out of bad situations by nerdponx on Monday December 18, 2017 @02:02PM (#15954308)
You might want to try Sourcetree if you haven't already. I felt the same way about Git GUIs for a long time, but Sourcetree actually does a good job of getting out of my way, and has a very nice commit history tree viewer to boot.
Re:Oh shit, git: Getting myself out of bad situations by rsp1984 on Monday December 18, 2017 @02:10PM (#15954408)
Actually I find Sourcetree one of the worst git GUIs out there. There are just so many bugs and kinks and glitches in it that I avoid it if possible.

I do like the Gitx-dev fork by Rowanj [1]. Clean and simple. Unfortunately just for Mac OS though.

[1] https://rowanj.github.io/gitx/

Re:Oh shit, git: Getting myself out of bad situations by nerdponx on Monday December 18, 2017 @04:14PM (#15955575)
I haven't encountered any of these bugs. But I do use it only rarely, the CLI is where I live most of the time. Good to know about alternatives.
Re:Oh shit, git: Getting myself out of bad situations by sirmarksalot on Monday December 18, 2017 @02:35PM (#15954661)
I've found Sourcetree to be way too slow. My team is currently using the GitFlow model, for various reasons, and that involves switching between branches fairly regularly. It also means that any commit to master involves a lot of steps. From the command line, this isn't a big deal because each of those steps takes a half second or so, but Sourcetree multiplies that by an order of magnitude, and the Sourcetree users are nearing a point of mutiny.
Re:Oh shit, git: Getting myself out of bad situations by tigershark on Monday December 18, 2017 @02:45PM (#15954780)
Source tree is the slowest software that I ever used. Git extensions is much much faster and I never had any performance problem with it.
Re:Oh shit, git: Getting myself out of bad situations by Someone on Monday December 18, 2017 @04:11PM (#15955555)
I dislike SourceTree precisely because it uses git terminology. Git’s terminology is bad enough, but it completely breaks down for me in a GUI, because I expect that GUI’s conventions there. For example, on the Mac (as in English, I think), a command named “Remove” removes an item from a containing item. “Delete” also destroys the item. SourceTree, however, uses “Remove” for “git rm” because Unix thinks “remove” destroys items.

To make matters worse, what in a Mac GUI would be called “Revert” or “Discard Changes” is called “Discard”, something that, to me, feels more destructive than it is.

End effect? We have “Discard” being less destructive than “Remove”, while, to me, it feels the other way around.

(I may remember this wrong, but if I do, I think that’s a sign of the problem of not following platform conventions in your software)

Re:Oh shit, git: Getting myself out of bad situations by andrepd on Monday December 18, 2017 @02:46PM (#15954785)
Not available for Linux, which is a damn shame.
Re:Oh shit, git: Getting myself out of bad situations by Tarean on Monday December 18, 2017 @01:32PM (#15953969)
I like fugitive - it feels like cli git without having to leave the editor. GAdd adds the currently file/selected lines, GBlame pulls up git blame information the ability to reblame, GStatus show the status with the ability to jump to/stage/unstage files and so on. Tried Magit for a while but it didn't play nice with evil.

Still hoping for a git repl that just does graph queries/transformations though.

Re:Oh shit, git: Getting myself out of bad situations by nullterminator on Tuesday December 19, 2017 @03:04AM (#15958545)
I use both.

Staging, especially partially staging hunks and lines when doing multiple things at once, is way easier in a GUI when you can scroll around for context and easily undo.

For everything else I prefer the command line, because it's faster and I know exactly what is going to happen. I can do what I need to do, no fighting. If I'm just committing everything, I use the CLI. If it's more complicated I use the GUI to stage and commit, and a CLI to rebase/merge/push.

Re:Oh shit, git: Getting myself out of bad situations by STRiDEX on Monday December 18, 2017 @11:50AM (#15952995)
I use sourcetree, but I would like a console feature that shows me what commands its running. Similar to sequel pro's "console" feature shows the raw sql being run.
Re:Oh shit, git: Getting myself out of bad situations by ccarse on Monday December 18, 2017 @12:01PM (#15953096)
There's an option in sourcetree, "always show output". This will keep the window that runs the commands open so you can always see what it did and git's output. I always keep this enabled.
Re:Oh shit, git: Getting myself out of bad situations by dilap on Monday December 18, 2017 @12:07PM (#15953147)
the commands themselves are not actually the lowest level, though! (and in fact, are kind of crazily mixed togther; most of the trouble people have w/ git is bad UX for the cli, imo.)
Re:Oh shit, git: Getting myself out of bad situations by Drdrdrq on Monday December 18, 2017 @05:04PM (#15955933)
True. Inconsistent and unintuitive options, oddly named commands (and this is coming from someone who enjoys using Unix clones).
Re:Oh shit, git: Getting myself out of bad situations by thelittleone on Monday December 18, 2017 @05:20PM (#15956041)
How about if someone made a GUI with a console at the bottom that showed the commands being executed along with results?
Re:Oh shit, git: Getting myself out of bad situations by mikedelfino on Monday December 18, 2017 @05:53PM (#15956236)
I like typing and I don't think it slows me down too much, so I pass. But it's a good idea.
Re:Oh shit, git: Getting myself out of bad situations by antoaravinth on Monday December 18, 2017 @11:03PM (#15957637)
This is exactly the same reason I too use CLI. But a word of caution Git Bash on windows has some serious problem(s). I remember, I lost my commit and in reflog it doesn't show up on CLI, however GIT UI showed the same! Not sure what's the issue, but it occurred for me twice.
Re:Oh shit, git: Getting myself out of bad situations by donarb on Monday December 18, 2017 @07:26PM (#15956758)
XCode rolled out a feature that allowed you to do an interactive commit just by click on/off switches. My first use of that feature screwed up the repo by committing the wrong pieces.

No thanks, it’s CLI for me, regardless if the IDE promises git support.

Re:Oh shit, git: Getting myself out of bad situations by CodeMage on Monday December 18, 2017 @06:26PM (#15956396)
The problem, as I see it, is not with the GUIs, it's with the CLI. Just look at the `reset` command: it does several different things, depending on what switches you give it. How would you represent that in a GUI?
Re:Oh shit, git: Getting myself out of bad situations by danmaz74 on Tuesday December 19, 2017 @02:30AM (#15958419)
Some git guis log the git commands they execute. Just look at those.
Re:Oh shit, git: Getting myself out of bad situations by krapp on Monday December 18, 2017 @07:23PM (#15956744)
I use either the GUI on Windows or a set of batch files I wrote to automate basic things.

As long as all you're doing is pull, branch, merge and commit, I don't think it matters.