Ask HN: Programs that saved you 100 hours?
629 pointsI learned about a ton of useful CLIs, desktop apps, and SaaS products from this thread (https://news.ycombinator.com/item?id=13887237).
But it was posted 3 years ago, and perhaps some useful stuff has emerged in the interim, hence my starting this thread.
Comments (516) 196 threads
Earlier commentsKeycloak [https://www.keycloak.org] OpenID Auth Server
nREPL + Cider [https://github.com/clojure-emacs/cider] Clojure's Network Repl and Emacs integration for live coding Clojure
Company Mode [https://company-mode.github.io] Emacs autocomplete mode
Continue this thread — 1 reply
> git config --global help.autocorrect 1
Based on bash history data, I've also added a simple alias to my bash config:
> alias gti="git"
[1]: https://git-scm.com/book/en/v2/Customizing-Git-Git-Configura...
> alias g="git"
With zsh: "history 1 | awk '{print $2}' | sort | uniq -c | sort -n"
With bash I think this should be "history" instead of "history 1".
I change this:
to: You would be surprised how useful this one change has been, answering historical questions easily, like how to generate that rsa key, or what packages did I install for that project last year.You can usuall answer questions with ^r instead of the man page. Or maybe:
Genuinely interested, why?
I'm a huge fan of the CLI in general, but for some things it just slows me down, git usage is one of those.
Random example: reverting a commit is 2-3 clicks, or a whole lot of typing.
Where the GUI falls down for me is more complicated things, like hard resetting a branch to origin or resolving merge conflicts.
Also, most of the git guis do things that I find distressing. For example, in one git GUI I tried a while back, I accidentally dragged a commit onto a branch listed in the sidebar. Only later did I realize the gui cherry-picked the commit into the branch without asking me for confirmation. It would do similar things if I dragged one branch into another.
They usually don't support the level of granularity I have on the CLI. For example, if I want to fix a commit on a PR based on feedback I've received, I can make the fix and `git rebase -i` will let me amend any of my previous commits (via 'fixup'). None of the IDEs I've tried support it; it's possible instead of an IDE one of the dedicated git tools like Kraken support this?
It's also just mildly terrifying when the IDE gives you a button with no further explanation for what it's actually doing. I.e. what do 'refresh' and 'sync' do in VS Code? The consequences could be dire: https://github.com/microsoft/vscode/issues/32405
> reverting a commit is 2-3 clicks, or a whole lot of typing.
Git revert is a single command; finding the commit to revert is the hard part. `git bisect` makes this easy, and I haven't seen any IDEs nail that one. That said, this is a rare use case.
Well for all of these people: I recently found Lazygit (https://github.com/jesseduffield/lazygit) which is a terminal UI for git and that does exactly what I've been looking for all these years, down to vim-like keybindings!
The true power of CLI apps comes from "alias" commands that you build up yourself. The following commands are great examples of this:
After a while I've learnt that a gui or cli-gui can never compose as well as the terminal can...> The true power of CLI apps comes from "alias" commands that you build up yourself
I usually agree. I spent way too many hours making aliases and I'm very proficient at it. But sometimes there's something like lazygit which does everything my aliases did, but slightly better as it gives me, for example, line-by-line staging and vim keybindings.
It is true that it does not compose, but I can still (and do) use the command line. It's just a nice increase of productivity in 90% of the cases (for me!)
Note: I'm not related to the lazygit project in any way, just very satisfied with it
https://magit.vc/
Visual walk through: https://emacsair.me/2017/09/01/magit-walk-through/
Fzf all you can, not just inside vim, but also use it to switch between tmux sessions in an instant. I have a tmux manager on top of tmuxp that is able to start / switch to already started sessions via fzf.
Identify patterns you use a lot and make snippets out of them. Create project templates.
Have a folder where you dump reference / things that need to be really easy to find, and set up vim to search into that instantly, no matter where you are.
Keep an inbox file to throw things in, make a wm bind a script to prompt for text and append it there via zenity. Don't throw links into it, it's gonna be a bookmark dump.
Make sure your todo system is a keybind away at all times.
Review your way of working, challenge, and improve it. Be lazy, but only when you afford it.
This point here I think is incredibly useful in general. When accessing your full to-do list feels like its own todo, you're gonna have a bad time
Can you access your todo system from your phone? I'm always torn on this, and why I keep my todos in google keep.
[1]: https://github.com/todotxt/todo.txt-cli [2]: https://github.com/mpcjanssen/simpletask-android
If you also need a browser, IDE, or any other non-terminal application open then i3 lets you tile those as well.
I haven't used it in a while since we switched to macs and ssh'ing to remote linux dev desktops but when I had an all-linux dev setup I remember i3 being pretty amazing.
Just having sensible defaults on a shell works wonders on my day-to-day productivity.
Add a couple of aliases for productivity and off you go.
All comments shown.
Couldn't load more comments. Check your connection and try again.