Live data from Hacker News

Show HN: I made a tool that made me faster at Git

github.com

21–30 of 235 posts

Re: Show HN: I made a tool that made me faster at Git

#21
Personally I have been typing all git commands manually into the terminal and never felt a need for GUIs or tools such as this.

There are a number of git shortcuts defined in my zsh aliases [0]. It goes like:

  # Git aliases
  alias g='git'
  alias ga='git add'
  alias ghb='git browse' # hub
  alias ghpr='git pull-request' # hub
  alias gp='git push'
  alias gpoh='git push origin HEAD'
  ...

Using these aliases, we rarely have to type more than 3-4 characters for a git command. Savings and efficiency not only add up over years of using git, but also accelerate as you become more proficient in using your own aliases that fit your special needs.

[0] - https://github.com/sungwoncho/dotfiles/blob/master/zsh/alias...

Re: Show HN: I made a tool that made me faster at Git

#22
post #19
post #14

Earlier quoted context omitted.

this readme really speaks to me

I'm out of the loop. What's the story here? Why are devs sad about Atlassian and Jira?

I don't think it's any specific event. Many of us are forced to use Jira for everything at work and it has grown from a simple bug tracker to a confusing one-place-for-everything mess.

Re: Show HN: I made a tool that made me faster at Git

#23
post #12

Earlier quoted context omitted.

I want to edit the commit message of a commit that is 5 commits in the past, that I have not pushed yet. What is the command to do it? Okay so it turns out I made a minor typo in that commit and I want to change it without adding any more commits. What is the command to do it? Okay so now I want to take all commits that have "bugfix pickme" in the subject and cherry-pick them to master. What is the command to do it?…

Which interface can do the above trivially with git?

SourceTree's interactive rebase feature is amazing at the first one. You can also just change a dropdown to "Amend" and start changing your most recent commit.

TortoiseHg's search bar was amazing at deciding whether you were searching for commit message, author, or what. You'd just type "bugfix pickme" and you'd get back only the commits you needed. Check out master, right-click the batch, graft. I have five different ways to search my Git repo and all of them combined aren't as good as TortoiseHg's search bar with revsets.

Re: Show HN: I made a tool that made me faster at Git

#24

Earlier quoted context omitted.

I'm a pro with TortoiseHg so have all the concepts perfectly clear. Git is still hard with tons of command line syntax to look up and alias, no good GUIs, and poor error messages when things go wrong like Excel locking a file or not being able to pull. TortoiseHg lets me treat my commits like little bubbles on a graph and rearrange them at will. Git isn't trying not to be hard.

Yeah, Tortoise makes life so much easier. :-) I just wrote about TortoiseGit here: https://news.ycombinator.com/item?id=17689294

TortoiseGit has a GUI? StackOverflow convinced my coworkers that it was just a Windows Explorer extension for people who were used to SVN.

Re: Show HN: I made a tool that made me faster at Git

#25

Personally I have been typing all git commands manually into the terminal and never felt a need for GUIs or tools such as this. There are a number of git shortcuts defined in my zsh aliases [0]. It goes like: # Git aliases alias g='git' alias ga='git add' alias ghb='git browse' # hub alias ghpr='git pull-request' # hub alias gp='git push' alias gpoh='git push origin HEAD' ... Using these aliases, we rarely have to ty…

Also simple but very handy:

  [alias]
  	amend = commit --amend --no-edit
  	ls = ls-tree --name-only --full-name HEAD
  	tree = log --graph --decorate --oneline --all
  	commit-date = "!gitcommitdate() { (export GIT_COMMITTER_DATE=\"$1\" && git commit --date=\"‎${GIT_COMMITTER_DATE}\" \"${@:2}\"); } && gitcommitdate"
There's also a whole boatload of commands in git-extras for those interested: https://github.com/tj/git-extras/blob/master/Commands.md

Re: Show HN: I made a tool that made me faster at Git

#26
post #19
post #14

Earlier quoted context omitted.

this readme really speaks to me

I'm out of the loop. What's the story here? Why are devs sad about Atlassian and Jira?

Jira has some asinine design issues, e.g. the only way you can link a git commit to a ticket is by putting the ticket ID into the commit message, generally has confusing choices for UI, code blocks {code}are annoying to add{code} and don't follow any existing conventions, integration with Confluence sucks, basic functionality is locked away in paid extensions, the list goes on

Re: Show HN: I made a tool that made me faster at Git

#27

Earlier quoted context omitted.

Yeah, Tortoise makes life so much easier. :-) I just wrote about TortoiseGit here: https://news.ycombinator.com/item?id=17689294

TortoiseGit has a GUI? StackOverflow convinced my coworkers that it was just a Windows Explorer extension for people who were used to SVN.

TortoiseGit is a GUI for Git that integrates with Explorer. You could indeed say it's geared toward people familiar with TortoiseSVN, though I'm not sure that paints an accurate picture of it. Unlike with SVN, I would argue you really do need to know Git on the command-line before you use TortoiseGit, but once you do, it makes life a hell of a lot easier than using Git on the command-line.

Re: Show HN: I made a tool that made me faster at Git

#28

Personally I have been typing all git commands manually into the terminal and never felt a need for GUIs or tools such as this. There are a number of git shortcuts defined in my zsh aliases [0]. It goes like: # Git aliases alias g='git' alias ga='git add' alias ghb='git browse' # hub alias ghpr='git pull-request' # hub alias gp='git push' alias gpoh='git push origin HEAD' ... Using these aliases, we rarely have to ty…

Personally I prefer to alias git to g, then setup my aliases in gitconfig.

https://github.com/GitAlias/gitalias

g f && g rom

git fetch && git rebase origin/master

You could go nuts and make it even shorter with https://github.com/thoughtbot/gitsh

gitsh > f & rom

Re: Show HN: I made a tool that made me faster at Git

#29

This looks great. For some reason I don't mind using the GUI tools to view history and branches but for commits always use the command line. This should save some time and much typing.

Different mental contexts, I think. I do the same thing.

Re: Show HN: I made a tool that made me faster at Git

#30
post #5

Why do people make a huge fuss over git? Why? What is the war they're fighting? Do they have performance anxiety? Are they fearful of some unerasable backlog of mistakes people will hold over their head? I have never found myself in a position where destruction of data was an issue. I have never found myself in a position where commit conflicts could not be reasoned about, in terms of the code itself, with total igno…

> Why do people make a huge fuss over git? Why? It's unclear to me what you're referring to, but the part I can answer is this: > How is git hard? IMHO because it is not intuitively obvious what it means for your "HEAD" to be "detached", or for you to "rebase" onto a "remote branch", or why "checking out" a file reverts your changes, or why "checking out" a branch suddenly clones its files, or why you'd "add" a missi…

I'll agree about the non-intuitiveness.

I like git, I love the idea behind it, I appreciate the benefits it provides me, and I want to get better at it and I strive to adopt all the commonly-endorsed best practices.

However, with all the slightly different means to ultimately the same ends – merges, rebases, patches, fast-forwards, squashes, fixups, messages, descriptions, notes – it makes me wonder if git is not a Frankenstein's monster by now with too much bolted on to it, that needs to revised from the bottom up and consolidated into a more streamlined interface.

It's kinda telling when all the GUI tools for git do each task slightly differently, and none of the GUIs (that I've tried so far) let you do everything from one app, so I prefer to keep a couple different ones open at all times: https://i.imgur.com/itWE4Gs.png

Post reply on HN