I usually comment with the same thing on these tip threads. And that is learn to rebind your keyboard. Make each key programmable modifier. Open apps, run scripts/macros instantly. My Karabiner config: https://github.com/nikitavoloboev/dotfiles/blob/master/karab... I go as far as binding keys to instantly type `console.log()` or `fmt.Println()` or the other language equivalent with my dot modifier key. Plus typing th…
Ask HN: What are your favorite developer-efficiency tips?
31–40 of 532 posts
Re: Ask HN: What are your favorite developer-efficiency tips?
#32A couple others have mentioned shell tricks. One of my favorites is using Alt-. (in Bash and Zsh) to insert the last argument of the previous command. Press it multiple times and it will cycle through the last argument of all previous commands. It's great for when you want to, say, `ls thing` and then `vim thing`. Yesterday I went looking for a similar key that would insert a copy of the last argument on the current…
(I'm on a phone and normally rely on muscle memory so it might be the wrong symbols).
Re: Ask HN: What are your favorite developer-efficiency tips?
#33I usually comment with the same thing on these tip threads. And that is learn to rebind your keyboard. Make each key programmable modifier. Open apps, run scripts/macros instantly. My Karabiner config: https://github.com/nikitavoloboev/dotfiles/blob/master/karab... I go as far as binding keys to instantly type `console.log()` or `fmt.Println()` or the other language equivalent with my dot modifier key. Plus typing th…
One thing I worry about with these extremely customized keyboard configs and such is that once you get used to them, you will have a hard time using any other computer when you suddenly need to. Maybe this isn't such a big problem with physical keyboards, but can be with e.g. text editor configs, which you can't take along if you need to SSH into many servers during a workday and work with whatever is installed there…
And I can still use other people's computers although with some pain.
Re: Ask HN: What are your favorite developer-efficiency tips?
#34I use a 4k TV as a monitor - I can easily see full size my code editor, terminal output, a page of documentation and the web app/site I'm working on all at once. It cuts down tremendously on the back and forth switching and reloading of things that don't feel like they take up much time but do materially eat into things.
Re: Ask HN: What are your favorite developer-efficiency tips?
#35Don't push a commit with a new feature without tests and documentation. Even for your personal projects. I started doing this a couple of years ago and it's hard to overstate the positive impact this has had on my macro productivity. I can come back to a project I haven't touched in six months and instantly start productively making improvements. Tests and documentation really are for future you.
Unfortunately I've gone in the opposite direction as you. I recently moved from a company that had a good automated test culture, to one that has a culture of manually testing things, often in production. Everyone, even the senior engineers who've been around for a long time, regularly lands changes that cause prod incidents.
There's actually quite a good canary/rollback system in place to deal with this, so a lot of people think everything's fine. But they don't quite realize how much more efficient things are if you can just make a change and run a test suite, and quickly have confidence that you didn't break things.
Re: Ask HN: What are your favorite developer-efficiency tips?
#36My main one's 5k2k and I could still use more space.
Re: Ask HN: What are your favorite developer-efficiency tips?
#37Re: Ask HN: What are your favorite developer-efficiency tips?
#38Re: Ask HN: What are your favorite developer-efficiency tips?
#39Learn to touch-type properly. I'm not a shit hot typist or anything, but it does make hours on a keyboard more pleasant. And (hate me) I do judge other devs on it. If someone can't be bothered to invest a few tens of hours on such a key productivity enhancement then what does that say?
Re: Ask HN: What are your favorite developer-efficiency tips?
#40A couple others have mentioned shell tricks. One of my favorites is using Alt-. (in Bash and Zsh) to insert the last argument of the previous command. Press it multiple times and it will cycle through the last argument of all previous commands. It's great for when you want to, say, `ls thing` and then `vim thing`. Yesterday I went looking for a similar key that would insert a copy of the last argument on the current…
`cp some/long/path/to/{foo,foo2}.txt`
(Though foo{,2}.txt is even shorter)