Ubuntu / Linux news and application reviews.

autokey


Because I couldn't get Sikuli to work on Linux, I searched for an alternative and remembered about AutoKey which even though I've known for some time, I've never got to use.

AutoKey is a Linux application (the latest version comes with a GUI for both Gnome and KDE) somewhat similar to AutoHotkey for Windows, which allows you to manage a collection of phrases or other text, and assign abbreviations and hotkeys to these phrases allowing you to insert them on demand into whatever program you are using.

Not only that, but starting with version 0.60 you can write Python scripts to automate virtually any task that can be accomplished via the keyboard. Unfortunately, the macros you may have created for previous AutoKey versions do not work with 0.60+.


AutoKey features:

  • KDE and GTK versions available, making AutoKey integrate well into any desktop environment
  • Write Python scripts to automate virtually any task that can be accomplished via the keyboard
  • Build-in code editor (using QScintilla in KDE or GtkSourceView2 in GTK)
  • Create phrases (blocks of text) to be pasted into any program on demand (uses the X selection)
  • Create collections of phrases/scripts in folders, and assign a hotkey or abbreviation to the folder to display a popup menu
  • Regular expressions can be used to filter windows by their title, to exclude hotkeys/abbreviations from triggering in certain applications
  • Scripts, phrases and folders can be attached to the tray icon menu, allowing you to select them without assigning a hotkey or abbreviation
  • AutoKey can track your usage patterns and present the most frequently used items at the top of the popup menu

AutoKey can be used for many things, it's up to you to decide for what you may need it. I've always wanted to be able to log-in to different websites no matter the browser I use, using just a keyboard shortcut (I know, this is not very good for security, but I use it for less important accounts on different websites). And since this automatic login can be achieved in just a few seconds, I made a video so you can see AutoKey in action:



Don't worry about the password being visible, it's a test account and also the password has been changed. Also, sorry about the video being so "quick", it seems there is something wrong with my desktop recording app.

Installing the latest AutoKey version in Ubuntu


AutoKey exists in the Ubuntu repositories, but that's an old version. To use the new AutoKey, make sure you firstly remove Autokey older than 0.60:
sudo apt-get remove autokey

Then, to add the AutoKey PPA, paste the following command(s) in a terminal:

-For Ubuntu Karmic:
sudo add-apt-repository ppa:cdekter/ppa


-For Ubuntu Hardy, Intrepid and Jaunty:
sudo bash -c "echo 'deb http://ppa.launchpad.net/cdekter/ppa/ubuntu ubuntu_version main' >> /etc/apt/sources.list"
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 6E3C0CE5

and replace "ubuntu_version" with hardy, intrepid or jaunty, depending on the Ubuntu version you use.

Then, to install AutoKey (any Ubuntu version):

-Gnome:
sudo apt-get update && sudo apt-get install autokey-gtk

-KDE:
sudo apt-get update && sudo apt-get install autokey


Note: for Ubuntu Hardy users, only Autokey-gtk is up to date, the KDE version being 0.54.5.


Other Linux distributions: Download the latest AutoKey version.

For help creating scripts, see the AutoKey wiki. There is also a Google Group where you may find useful info. And finally, you can also get support on AutoKey thread @ Ubuntuforums.org