Acceleration

From Productiveprogrammer

Jump to: navigation, search

Contents

[edit] IDE Acceleration

[edit] Templates

Templates are a great way to avoid retyping boilerplate code. Eclipse comes with lots of code templates defined, which are accessed through preferences under Java|Editor|Templates. You can also define your own, like these:

Adding a log4j logger to a class (bound to keys 'l4j'):

${imp:import(org.apache.log4j.Logger)}
private static final Logger log = Logger.getLogger(${enclosing_type}.class);

Importing JUnit library classes (bound to 'ju'):

${imp:import(org.junit.Test)}
${impst:importStatic('org.junit.Assert.*')}

[edit] Flash Cards for Keyboard Shortcuts

In my Productive Programmer talks, I talk about using flash cards to help learn keyboard shortcuts. One of my colleagues (I'm sorry, I can't remember who) spent the time and effort to do this, for both Eclipse and IntelliJ. Here they are:

Eclipse flash cards

IntelliJ flash cards


There are a lot of cheat-sheets/refcards on the web. You also find them in the help menus of your favorite IDE's. (e.g. [Refcardz] require registration)

I've found lots of cheat sheets at http://www.addedbytes.com/cheat-sheets/ ranging from subversion and css to rails and mysql.

[edit] Hack Your Keyboard

Hitting the ctrl key all the time isn't very ergonomically comfortable so I like to build up the ctrl key to about twice its height with a few layers of foam tape (the kind that's used for taping posters to walls). When the ctrl key is about twice the height of my other keys I can press it down with the heel of my hand while at the same time leaving my finger tips at the center of the keyboard. I find this setup makes working with the ctrl keys (my editor is emacs) both faster and more natural than contorting my hands to hit ctrl keys with the pinky.

[edit] Application Accelerators

[edit] FireFox

MouselessBrowsing(MLB) - From the website: "Mouseless Browsing (MLB) is a Firefox-Extension which enables you to browse the internet with the keyboard. The basic principle is to add small boxes with unique ids behind every link and/or form element. You just have to type in the id and press enter (there is also an automatice mode available) to trigger the corresponding action i.e. following a link, pressing a button or selecting a textfield" I have been using it just a day and already really like it. It's not perfect yet, and doesn't handle gmail well, but a great tool over all under active development.

Personal tools