Lurker News
I recently started integrating tmux and vim into my workflows. Obviously, it was a huge efficiency booster. What are some other tools (custom built or off-the-shelf), hotkeys, workflows that were game-changing for you as a dev? I'm interested in hearing about anything and everything (stuff from ctrl+l to clear the terminal to little-known git commands to larger-scale strategies like CI/CD)

Comments (522) 158 threads

Earlier comments
nikivi3 replies#
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 things like `Thank you` with dot+spacebar press.
https://github.com/nikitavoloboev/dotfiles/blob/master/karab...
The other tip that paid off in time is starting a wiki. And building an interface to access contents of the wiki instantly.
Wiki: https://github.com/nikitavoloboev/knowledge
Interface: https://github.com/nikitavoloboev/alfred-my-mind

naavis2 replies#
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.
nikivi1 reply#
I have a bind to turn off all my binds if anyone else wants to use my computer.

And I can still use other people's computers although with some pain.

chadlavi2 replies#
as a caps-to-ctrl remapper, I can't imagine how crippling it would be to have serious remaps or Dvorak or something and try to use someone else's keyboard. Doesn't seem worth it.

Continue this thread — 2 replies

mekster#
I always find this argument nonsense. Most people will be on their computer for 99% of the time and sacrificing for the rest of 1% doesn't make sense. I had a colleague who had been using vim without customization because of that reason and he's always on his computer but I find the reasoning very odd.
ashnehete2 replies#
Maintaining a Wiki or any sort of extensive note taking operation requires a lot of dedication and I guess practice? Do you have any tips for someone who wants to start out? Is there a smaller step that one could take initially?
erichurkman1 reply#
I don't use a wiki but instead use Bear (https://bear.app) which gives cross-referential tags and a slick sorted tree of tags. I tag every article ('note') with a set of tags at the top.

#d/2020/05/08 #fam/sis #fam/gifts — notes around a conversation I had with my sister today about potential gifts .
#d/2020/05/05 #recipes/dinner #recipes/c/italian — notes a ravioli recipe I made on 5/5. If I later make it for a group dinner, I'll tag it, too, so I can track when I made things for who and collect longitudinal feedback and recipe changes.
#todo/today is things that need to get done today; things that don't will get moved to other notes.

RBerenguel#
In case you want to generate a graph of your notes (via graphviz for now), I wrote a project recently (I'm working on a D3 version of the graph "at the moment" although it won't happen until at least tomorrow, today is off-programming day): https://github.com/rberenguel/bear-note-graph

edit: parse error, unbalanced parentheses

discreteevent#
Use mind maps. Its quick (much quicker than a wiki) and makes it really easy to reorganise a mess. Freemind/freeplane is good.
kanyethegreat1 reply#
Holy shit... that wiki and alfred workflow is INSANE. I am so jealous. Do you find that you're able to discover what you're looking for pretty instantaneously? Any general tips for organizing (sorry if you cover this in the wiki, haven't dived into it yet, but i'm going to!)? also, huge fan of keyboard remapping. I use karabiner, kinesis advantage, and a couple kinesis foot pedals (had some rsi issues, but all this opened my mind to the possibility of experimenting with key mappings and input movements).
bbarn7 replies#
This is a bit of a departure from the question you asked, but I'm always amazed how much people tend to hyper-tune their dev environments, when in reality, most of my time is spent thinking how not to write code. I get just as much work done on a completely vanilla macbook with VS code installed on it as my editor-obsessed peers with obsessively optimized setups can.

How much actual code are you writing? I'd be really concerned with myself if I am putting out so much code that I need to be concerned with my text input speed.

SimonPStevens#
I spent quite as few years as a contractor and I quickly discovered the best way to be effective was to learn how to be effective with everything in the default settings. At every new place I went I could just jump right in. No need for any time spent fiddling with settings or tweaking and installing pluggins.

Although a slight counterpoint is that I also used to have my git settings file stored in a github gist so I could just grab my latest one and every new environment would have the same set of aliases I was used to.

jmchuster#
Your tooling isn't just about writing code, it's also about reading, analysis, debugging, research. You think about the code, have an idea, need to look up how something works, think some more, have this constant back and forth. Optimizing your environment minimizes the friction, and allows you to immediately get answers as soon as you have a thought about something, so you don't lose your train of thought.

You also want to be able to run quick experiments, same idea, get the answer to a question you're thinking about as fast as you think of it. And then once you actually know what you want to do, don't you want to have as smooth an experience executing your fait accompli? The primary focus is minimizing friction, and speed is just the observable side effect.
And then of course you can't ignore the natural human enjoyment that comes from customizing things to exactly how you like them.

ExpiredLink#
IIRC, the average developer output is 10 lines of code per day.
jonnypotty#
For the most part I agree with you, but it got to the point at work where I could regularly type faster than eclipse (usually some shitty background tasks messing things up but still) this actually slowed me down as well as making me angry, which is probably the way to make me least productive and ranty. Like, how can this be the case that in 2020 I can type faster than a computer displays text in a professional IDE. Jesus christ. Oooo calm. Using sublime text now and just using eclipse for the debugger. Calm. Calm.
joatmon-snoo#
It isn't so much the total LOC that I write (and delete) in the process of making a change so much as it is the friction and mental overhead of the change. The more I can focus on making the semantic change that I care about, the better.

Admittedly my vim setup doesn't even have YCM because I don't care enough to do it. But there are other minor things (swapping : and ; in control mode, mapping jk as ) that I've done that I hate working without now.

fragmede#
Lines of code are the wrong metric and turning dev environments isn't going to get you to type faster. If you're happy with VS code on OS X with zero customization, more power to you :) The "obsessively optimized setup" isn't the results of a single week-long binge, which may lessen how obsessive that seems. A setting here or there, after a few years, results in a comfortable dev environment. The comfort of this environment extends the ability to make code happen.

Coding is, as you've noted, rarely about typing speed. The larger a program gets, the longer the files get, the more spread out across different files and directories it gets. (Consider yourself very lucky if the programs you work on can fit entirely inside your working memory! Others have bigger programs to work on, or differently shaped working memory) Being able to find "that thing you saw that one time" is paramount. How you find it, is an entirely personal choice, but being able to find it, quickly, and without breaking out of flow state, is the goal. Whether it's by learning VS code (which has a expansive collection of settings and extensions to "obsessively" tune), or by installing ag. (And yes, for the obsessive, the merits of ag vs ripgrep/other is a fun rabbit hole to fall into.)
Still, between from when you start coding, to when you share the diff with anybody, coding is an intensely private activity (that some choose to share with others). As such, whatever works. If trying to open a file while traversing a tree view is distracting enough that it takes couple tries, and you don't mind taking a couple times, great. If I've got my dev env setup to so I can open the file from the command line where I've already got the filename, that's cool too. If I want to learn VS code's command bar syntax so I can open it from there, that also works. And if you can open that file first try, while simultaneously navigating a stream of code, good for you.
End of the day, comparing "just as much work done" with two independent variables (the configuration, and the person using the setup) and no control, is as foolish as managers trying to quantify programmer output by counting lines of code.

therealdrag0#
I donno. I use IntelliJ and when I pair-program with someone who knows how to use its features vs someone who treats it like a basic text-editor/compiler, is night and day difference.

If I am 'riding shotgun' and say stuff like "look up that definition" or "find all the implementations of that method" or "go to ABC" and they just look at me like a deer in the headlights, or start clicking through the file tree, or do "find text in project", then they are going WAY slower than they could be going.
So if "obsessively optimized" includes learning your tools, then it returns rewards.

XCSme5 replies#
The REST Client VSCode extension[0] let's you send HTTP request from any file open in the editor. I use it to call the Cloudflare API to purge the cache of my site after I make changes. It's also really useful to test new APIs or quickly create a bunch of file/requests for the current project.

I use PHP on my landing page[1] so I can make changes and publish them immediately without any build step. This way, whenever I see something wrong with my site or have a new idea, I just open the editor, change the file, save and push all changed files through FTP to the server using the VSCode SFTP extension[2]. This means that I can instantly publish changes from VSCode without running any command, just by using shortcuts. This way I can make the changes immediately instead of having to create reminder tickets.
Automate the tasks you do often. For example, I had to download invoices from Envato every quarter, which was annoying because they don't have a button to export the PDFs of all invoices. I created a puppeteer script (headless Chrome) to download the CSV with the list of invoices, go to the URL of each of those invoices, print the file as PDF and save it into the correct folder. The automation part can also be just creating a faster build process, unit tests or even subscribing to notifications/alerts for a social site for the content you are interested instead of checking everytime if there's anything you might like.
[0]https://marketplace.visualstudio.com/items?itemName=humao.re... [1]https://usertrack.net/ [2]https://marketplace.visualstudio.com/items?itemName=liximomo...

CraftThatBlock#
Same for IntelliJ-based editor! It's incredibly useful to store the .http files inside git repos, an have it tracked alongside with code. It's similar to Postman or Insomnia, but tracked (and synced), and built-in
kanyethegreat2 replies#
This is awesome. I usually just have a scratch file that uses an http library (eg. requests for python) and log the response. Do you prefer this over something like postman?
XCSme#
Yes, I only use this now. I used postman for a while, but I remember last time I tried it, it was way too complex, had to create projects or accounts (or something like that) to make a simple request.

I now only use this VSCode extension, I have some .http files saved in my project with requests I do often. If I am trying an API online, I just copy-paste their cURL examples and run them, it's useful because on Windows there is no cURL cmd preinstalled. It's also nice that you get code highlighting by default in VSCode for the .http files.

XCSme#
Another big advantage is that you don't have to open a new console or application. You just do CTRL+N to open a new file and ALT+CTR+R to send the request. So you can do CTRL+N, write google.com, ALT+CTR+R and you can see the source-code of google.com in a VSCode file.

Having the request in a file means you can easily change it, save it or version it.

gavinray1 reply#
I use this too, it's great!

My usecase is that I often have queries for debugging purposes for API's that I need to send, so in my repos I keep a requests.http file for quick-access.
I also put them in repos for projects I publish (like boilerplate/demo API's) along with a screenshot and a note + link to the extension in the README because you have a working spec for API requests, and so do if/when I ever revisit it.
Tiny extension saves a ton of time and super useful.

vmception#
(hi, in reference to an old thread I think you got nbomb'd on your trip)
rhlsthrm#
The REST client extension is so awesome, ever since I figured out how to use it I've been trying to convince everyone I know to use it instead of Postman, cURL, etc. It's just so easy to save common requests to a file and have everything in my editor.
darekkay#
I've just learned about this extension today from a Twitch stream. First I thought: "Nice, another great IntelliJ IDEA feature got ported to VSCode" (I think the syntax is exactly the same). But seeing the VSCode extension was first released in 2016, it looks as if JetBrains actually copied this one. Always nice to see how IDEs/editors inspire each other.
jasonpeacock#
Only work on one task at a time.

Do small tasks immediately - reply to that email, merge from master, do that CR, etc. Delaying small tasks tends to abandon them.
Keep your workspace clean (physical & virtual).
Update docs as you use them.
Say "No" often.

Load more comments