What are the best plugins to increase productivity on Emacs

Over a year ago now, I went looking for the best plugins to turn Vim into a full-fledged IDE. Interestingly, a lot of the comments on that post were about how Emacs already has most of these plugins built in, and was already a great IDE. Although I can only agree about Emacs' incredible versatility, it is still not the ultimate editor when it comes out of the box. Thankfully, its vast plugin library is here to fix that. But among the plethora of options available to you, it is sometimes hard to know where to start. So for now, let me try to assemble a short list of the indispensable plugins to increase your productivity while using Emacs. Although I am heavily geared towards programming related productivity, most of these plugins would be useful to anyone for any usage.

1. Ido-mode

Maybe one of the most useful plugin for beginners, Ido stands for interactively do. It replaces most of the dry prompts with a fancy character matching menu. For example, it will replace the normal prompt to open a file with a list of all the files in the current directory. Type any string, and Ido will try to match it with the most appropriate file. It makes it really easy to visualize your actions, and also to quickly get through a folder where all files are named with the same prefix.

2. Smex

Not the most famous one, but a good place to complete what Ido-mode started: Smex can be a fancy replacement to the normal 'M-x' prompt, with a heavy inspiration from Ido-mode. It brings the same interactive search for the commands you would normally have to type after calling 'M-x'. It is simple and efficient, and a great way to save those additional few fractions of a second you normally need.

3. Auto Complete

Before knowing the existence of this plugin, I spent half of my time on Emacs pressing ‘M-/’ to complete my words. Now, I have a fancy pop-up to do it for me. There is not much more to say about it, except that we all need it.

4. YASnippet

This one is really for the coders. There is always some piece of code that we feel we use all the time. For me, it's 'var_dump(...); exit;' to debug PHP. After a while of typing it over and over, it just occurred to me that I could have it pre-recorded and easily accessible as a snippet of code. With YASnippets, it's easy to import snippet files or make your own. After that, a simple press on the tabulation key will expand a small keyword into a chunk of pre-written code easy to navigate through and modify.

5. Org-mode

For disclaimer, I have only recently started using Org-mode. But it has already blown me away. From the hundreds of written pieces I have seen around, Org-mode can change your life. The idea behind it is simple: it is a mode that simplifies note taking while keeping a plain text format, making it easy to navigate through lists of tasks and various data, and perform operations such as filtering by priority or due date, or setting a recurrence. Yet, from this simple idea, you can accomplish a lot, and it is easy to get overwhelmed with all the options. Rather than a long explanation, I urge you to go through available tutorials, watch a lot of videos, and see by yourself how powerful Org-mode is.

6. Helm

Some love it, but others are not such a big fan of it. I am part of the later. But with such a huge following, it is impossible to avoid it. Helm aims to transform your Emacs experience completely. Simply described, Helm is a framework that will help you find a file or a command quickly from within Emacs. Based on your input, it will try to use word completion to guide you to the action you have in mind. The feeling is a bit weird at first, but for some, Helm is a religion of its own. Although I am not its fan, I do appreciate helm-occur which a great tool to search for strings in a large document as it shows all occurrences in a separate buffer, making it easy to navigate through them. If you are looking for a quick demo to understand what Helm can do, I recommend this post.

7. ace-jump-mode

Another plugin with a big following that I am trying to get on board with is ace-jump-mode. Master this plugin, and you will be promised to transcend the usage of a mouse. Simply described, by triggering ace-jump-mode with a shortcut of your choice, you will be prompted for a character. Enter one, and all words starting with that character will be highlighted with a unique letter. Enter one of the letters on screen, and your cursor will jump straight to the word it is highlighting. I have to admit that it is pretty hard to get the reflex to use it, but once you have it, it will increase your movement speed in a document by a lot.

8. find-file-in-project

If you like Sublime text and its very handy 'Ctrl-p' fuzzy search to open any file in a project, then you will love find-file-in-project (or ffip). After setting it up by declaring the root of your version control folder, you can summon easily a cool text bar that quickly scans and searches through your code base for a matching file based on the name you input. I like to have it bound to the F6 key on my keyboard. It is simple and very handy if you do not know the complicate directory structure from the top of your head.

9. Flymake

For IDE lovers, I think that syntax checker is one of the most powerful features. It is great for beginners and handy for tired programmers. And thanks to Flymake, Emacs users can enjoy it too. Since I work in PHP a lot, Flymake does not need any extra configuration. As I write my code, it will automatically check my code and highlight any line that contains a problem. For compiled languages, Flymake will look for a Makefile that it will use to check your code. Absolutely magical.

10. electric-pair

Last, but not least, electric-pair is one of the simplest yet most powerful plugin in my opinion. It just automatically closes whatever parenthesis or bracket you open. It doesn't look like much at first, but trust me. After struggling for the hundredth time to find that matching parenthesis, you will be glad to have a plugin to ensure that all your expressions are balanced.

To conclude, Emacs is a fantastic tool. Probably not a shocker. Try these plugins and watch as your productivity goes through the roof. This list is of course not exhaustive at all. If you want to bring your contribution, feel free to do so in the comments. I am myself always looking for new plugins to try and new ways to experience Emacs.

Subscribe to Xmodulo

Do you want to receive Linux FAQs, detailed tutorials and tips published at Xmodulo? Enter your email address below, and we will deliver our Linux posts straight to your email box, for free. Delivery powered by Google Feedburner.

Support Xmodulo

Did you find this tutorial helpful? Then please be generous and support Xmodulo!

The following two tabs change content below.

Adrien Brochard

I am a Linux aficionado from France. After trying multiple distributions, I finally settled for Archlinux. But I am always trying to improve my system by stacking up tips and tricks.

Latest posts by Adrien Brochard (see all)

14 thoughts on “What are the best plugins to increase productivity on Emacs

  1. Not sure whether or not evil is classed as a plugin but it certainly makes Emacs more pleasant to work with.

  2. A brief rundown, in case they don't add their own justification:
    Projectile knows more about project structures than FFIP, and works on more non-VC projects out of the box. FFIP is faster for large projects, though.
    Company is easier to develop backends for, but switching from ac to company didn't impact my user experience much.
    Helm vs Ivy is down to personal preferences. Helm is very powerful, but also is a big departure from the vanilla Emacs interface for finding/selecting things. Ivy is more like Ido, being useful but unintrusive.
    Avy is the successor to ace-jump. Ace-jump is no longer under active development, and Avy offers all of it's features and then some.
    Flycheck offers more checks out of the box than flymake, and offers more features / customization options than flymake. Flymake is included in Emacs.
    Smartparens does everything electric-pair does, and many other pairing utility functions, like wrapping and movement/slurp/barf commands. It is like Paredit, but works better for languages without sexp syntax.

  3. GNU Emacs does not have "plugins" and there is no plugin API (application programming interface) with API "hooks" and special (always limited) access given to certain services.

    It may seem an esoteric point, but it is fundamental to the way GNU Emacs works. GNU Emacs is basically a Lisp interpreter with text editing functions written in Emacs Lisp. Of course it has extended beyond mere editing with org-mode and IRC clients, Gnus etc built in. And that's the point. Any extension you write for GNU Emacs uses the same Lisp as anything else does. It's not ported through some second-class "plugin API" but treated exactly the same as any other Lisp code in GNU Emacs.

    The code is not a discrete chunk of code talking to GNU Emacs through some limited interpretation channel, it is a fully integrated part of GNU Emacs.

    In the same way, GNU Emacs does not have a "configuration file" where you are allowed simply to pass certain built in functions a value. The init file (.emacs or wherever you keep it/them), is in fact a functioning Lisp programme that customises GNU Emacs. It could, if you wished, contain huge complex extensions to GNU Emacs. The only reason this does not happen is since the .emacs file is generally kept for your own personal simple customisations. We load large and complex extensions from other files because a bit of organisation makes sense for humans.

    Add to all this the fact that GNU Emacs is free sofware (as in freedom of speech), and the restrictions of software that has secret code and a limited granting of an API on the whim of the developer ... well the attractions of GNU Emacs (and other free software of course) start to become clear.

Leave a Reply to dgrb Cancel reply

Your email address will not be published. Required fields are marked *