Software engineers are great at automating workflows and focusing on how to do them evermore efficiently. The best engineers I know also apply this meticulously to their own workflows. They're always looking for ways to save a couple of clicks or keystrokes in actions they perform every day.
There's a lot you can automate yourself, but many software development environments (IDEs; short for Integrated Development Environment) are packed with productivity features that allow engineers to be as productive as possible. This blog post is an exploration into such features and how I can see those ideas be applied in other software for which this previously wasn't possible.
The value of optimising small tasks in the long term is often underestimated. To see this, let's consider an example. Most engineers use Git for version control. Let's say you commit code 5 times a day. And for simplicity let's assume this usually means adding all changed files and adding a commit message. You would type:
git add . <ENTER> git commit -m "Fix for scrolling on iOS" <ENTER>
If you ignore the commit message itself, say the rest of the commands takes you about 3 seconds to type (yes, I timed this). Over a year, assuming you work 20 days/month, this takes 1 hour (20 * 12 * 5 * 3s). In < 5 minutes, you can add a function to your *sh setup so that instead you can type:
gc "Fix for scrolling on iOS"
to do exactly the same. This probably takes you less than a second. That saves 40 minutes in a year (ok, only 35 in the first year as you have to set it up). Now, I hear you thinking: "that's only 40 minutes in a year...". But this is only one tiny action. There are hundreds of repetitive small actions we do every day. Added up I think you can easily shave off at least a couple of days. And many of these last for many years.
Besides the time savings, only having to use a minimal number of keystrokes or clicks feels fast, which then in turn feels productive. It also gives you less chance for your mind to drift while you are entering the routine commands. I don't have numbers for this, but I think these combined have a large effect.
Good IDEs provide a nearly endless list of features that allow you to be more productive, but I'm going to focus here on the ones that I find most impactful and whose ideas I believe can be ported to other software such as browsers, operating systems, and office suites, which often strike me as rather inefficient.
This list will use examples from IntelliJ PyCharm, but many IDEs will share similar features.
One of the biggest timesavers for me is universal search. I can hit Shift twice and immediately search across the whole project I'm working on:
Note that this doesn't just search for filenames. It also indexes the file contents and structure. So I can immediately search for a particular class or method. I rarely ever actually navigate the folder structure of the project to find something, which saves tons of time.
This one has made it's way to OS X in the form of Spotlight (Cmd + Space):
It's a great feature that I heavily use, especially because it also searches file content for most common file types.
I can imagine this also being useful in Chrome. I often have way too many tabs open (who hasn't?) and it'd be great if I can hit Shift twice, type a keyword, and it brings me to the tab. This is coming to Chrome OS, so we may have it soon on other OSes as well.
What would be amazing though is if Spotlight starts to (at a basic level) understand the content it indexes, the relations between the files and the interactions we had with them. If it could interpret this data well enough, it could answer queries like: "slide deck we presented to customer X last year", "my tax returns from the last 10 years", "proposal that Tom emailed about yesterday" or "contracts with client Y that are still in effect". With Spotlight in its current form, I still try to maintain a reasonable directory structure so that I can find a file (the lengthy way) even if I don't remember the content or filename. The goal of a directory structure is to organise your files in a way that makes sense to you so you can retrieve files easily. A more intelligent Spotlight can remove the need for that, not only saving you time retrieving files, but also saving you time organising them.
A next (harder) step would be to actually answer the queries I have about these files instead of just retrieving the right files. Perhaps being great at retrieval would be a good intermediate interface though.
On-the-fly error highlighting and autocomplete
While I'm typing code (of which a large part is navigating autocomplete to avoid typing), PyCharm will immediately highlight any errors:
This is very similar to a spellchecker and it's great mainly because it gives immediate feedback so I don't have to context switch, which is expensive. What distinguishes the error highlighting in an IDE from a spellchecker is that it highlights a large number of errors one typically makes, while a spellchecker is quite limited to, well, spelling checks. Solutions like Grammarly are already better as it also performs sentiment analysis and grammar checks, but it doesn't check any content errors.
Imagine an interface that also highlights content errors. If someone sends me an email with a quote attached and I reply that I find a price of $100 too much while the quote says $150, I want my email client to highlight my error. Similarly, if I'm building a deck in Keynote in which I quote findings from a report, but the report I'm quoting has slightly different findings, I want Keynote to highlight that. It may be a long time until an AI solution can highlight all your content errors, and some it may never be able to, but even detecting a significant amount of them would be great progress.
Of course, once you have error highlighting, it should also be fairly straightforward to turn that into autocomplete, which then saves you even more typing.
Intelligent refactoring and navigation
A final big timesaver is the ability to refactor code with a single click. If I want to move a method from one class to another, I can do so with one click and all references to it will be updated. It can do this because it understands the structure of the code. Because of this, it's also really easy to navigate around the code. I can (Cmd+)click on any method and it'll bring me straight to the definition:
Note that these are not simple find (and replace) actions. If I have two methods named the same, but in different parts of the project, the IDE will know which one I want to navigate to or refactor. This also shows where this quickly breaks down: references in documentation (which is unstructured text) fall back to a find and replace, which then often either is too narrow or too broad.
In text processing software such as Pages or MS Word, any refactoring beyond a simple find and replace is manual. If you move paragraphs around, you may need to edit the first/last sentences of them so that the text still flows well. It'd be great if the editor of the future can do this for you, or at least give you a suggested sentence. The same applies to navigation: if in a document or message I talk about some other document I want to be able to immediately click into it without having the explicitly link them. In some cases, I may even want the software to explicitly construct this link. For example when I type "Please find attached invoice 304", then my email client should attach that invoice automatically. Those should not be actions we have to do manually.
The reason why all of these features work well in IDEs is that they can operate on structured data: code. There's a defined syntax, a compiler that can spit out errors, static analysis, etc. All of the features mentioned rely heavily on the fact that it's easy to interpret code and many of them break down if the code contains errors (good luck doing automatic refactoring on code with syntax errors).
Traditionally this was difficult to build outside the realm of code because a lot of the data we produce and work with is unstructured (such as text). With AI becoming increasingly powerful on unstructured data (in particular on various problems operating on text), that should become a solvable problem soon. In fact, I think many of these could already be build in limited fashions.
I think we'll start seeing more and more of such interfaces in all sorts of software, allowing us to be more productive and do fewer straightforward tasks. Given IDEs have been operating in a space where more has been possible due to the structured nature of code, they will be a useful source to learn from as we improve on operating on unstructured data.
Enjoyed this post? Subscribe below to get the latest posts directly in your email, leave a comment, or follow me on Twitter.