There are already a couple of manuals out there that describe how to make Gedit fit for development in Ruby (or other languages). See here or here for example.

Unfortunately many plugins no longer work with newer Gedit versions, since 3.8 there were some fundamental changes.

So the recent Gedit were less useless and I already decided to move to vim due to all this shortcomings.
But after having a closer look at the plugin list at the Gnome wiki I came to quite good results with Gedit 3.10. It seems quite a few plugins have appeared that replace the old ones and also Gedit bugs have been fixed.

In order to help setting it up here a quick manual.

First of all install gedit and the gedit-plugin package on your system. Then add the following 3rd party plugins:


To install plugins move the necessary files to ~/.local/share/gedit/plugins/ and then restart gedit. For the rest of the setup we'll use the plugins distributed with gedit packages.
To get a decent development editor you should at least enable following plugins (Edit > Preferences > Plugins Tab):
  • Code Comment – allows to comment/uncomment multiple lines with Ctrl. + M (+ Shift for inverse behaviour)

  • Draw space – as spaces are used in ruby instead of tab displaying spaces helps to easily see intendation and also to spot uncommon characters and trailing whitespaces in your code.

  • File Browser Panel – on by default, display the sidepane in the view menu.

  • Multi edit – if you want to edit multiple places at once

  • Pair character completion – the plugin installed above to comeplete closing characters. Use this instead of the build in plugin (called Braket Copletion), since it allows to mark text first.

  • Quick open – helpfull to open files fast by pressing Ctrl. + Alt + O and type.

  • Smart highlighting – Plugin installed above, helpfull to find same words in a document.

  • Snippets – easily missed but quite powerful in completing code structures. In ruby code for example just write def and press Tab and it will create a template of a method for you

  • Sort – for sorting listings.

  • Trailsave – the plugin installed above. Deletes trailing whitespaces.

  • Word completion – just a common completion of existing words.

Screenshot Plugin Tab

To finish your setup you might want to change some settings in the Edit > Preferences window:
  • Display line numbers

  • Display right margin at column 80

  • Disable text wrapping

  • Highlight matching brackets

  • For Ruby set tab with 2 and insert spaces instead of tabs

  • Enable automatic intendation

  • Disable backup file creation and autosave (as you proably work with a version control system anyway)

  • As color theme I prefer Oblivion

  • As Font I just use the system font, which is set to Ubuntu Mono 11 in my case.

After all this you should end up with a pretty decent development editor.

* the pair char completion plugin has an issue when used in combination with the word autocomplete. When you press enter there a linebreak instead the autocomplete. I fixed this an provide it for download here.

Noch keine Kommentare

Kommentar schreiben

Die angegebene E-Mail-Adresse wird nicht dargestellt, sondern nur für eventuelle Benachrichtigungen verwendet.
Umschließende Sterne heben ein Wort hervor (*wort*), per _wort_ kann ein Wort unterstrichen werden.
Gravatar, Twitter, Wavatars, Favatar Autoren-Bilder werden unterstützt.