Hacker News new | past | comments | ask | show | jobs | submit login

Does anyone know why stash names are so ugly? I've always found typing "git stash apply stash@{3}" to be pretty painful (not to mention redundant).



You might want to check out the Bash completions for Git: https://github.com/git/git/blob/master/contrib/completion/gi.... They work with stash names so can take some of the pain away.


It's a generic git syntax for "this reference 3 versions ago", see `man git-rev-parse`

It works for other things too, e.g. you can undo rebase with `git reset master@{1}` (i.e. reset master to previous location of master).


Making an alias to use something like `stash apply #3` shouldn't be too complicated


That's a bad idea, it would need quoting as the `#3` would be considered to be a comment in most shells.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: