Skip to content
forked from autokey/autokey

A Python 3 port of AutoKey, a desktop automation utility for Linux and X11.

License

Notifications You must be signed in to change notification settings

sonyeric/autokey

Repository files navigation

AutoKey-Py3

AutoKey-Py3 (GitHub) is a Python 3 port of AutoKey, a desktop automation utility for Linux and X11.

New features have since been added to AutoKey-Py3 after the initial porting. Read new features for details.

There are two GUIs for AutoKey-Py3, GTK and QT, and they have different dependencies. If you use the GTK GUI, there is no need to install dependencies for the QT GUI and vice versa.

Python modules (common):

  • dbus-python
  • pyinotify
  • python-xlib
  • typing

GTK GUI:

  • PyGTK
  • GtkSourceView

QT GUI:

  • PyQt4
  • PyKDE4
pip install --user git+https://github.com/autokey-py3/autokey

The "--user" option for pip may be removed if you intend to do a system-wide install. You can also add the "-e" option to pip to install in editable mode. Editable installs currently work only with the GTK GUI.

virtualenv --system-site-packages ~/autokey
. ~/autokey/bin/activate
pip install git+https://github.com/autokey-py3/autokey
# common dependencies
apt-get install python3-pyinotify wmctrl xautomation imagemagick
# dependencies for GTK GUI, install only if you intend to use the GTK GUI.
apt-get install python3-gi gir1.2-gtk-3.0 gir1.2-gtksource-3.0 gir1.2-glib-2.0 gir1.2-notify-0.7 python3-dbus zenity
# dependencies for QT GUI, install only if you intend to use the QT GUI.
apt-get install python3-pykde4 python3-pyqt4.qsci python3-dbus.mainloop.qt kde-baseapps-bin
# execute as non root
pip3 install --user python3-xlib
# install AutoKey-Py3 from PyPI or
pip3 install --user autokey-py3
# get the development version from GitHub
pip3 install --user git+https://github.com/autokey-py3/autokey

Available in the AUR.

To install from PyPI:

pacman -S --needed wmctrl hicolor-icon-theme python-dbus python-pyinotify zenity xautomation imagemagick xorg-xwd
# dependencies for GTK GUI, install only if you intend to use the GTK GUI.
pacman -S --needed python-gobject gtksourceview3 libnotify
# dependencies for QT GUI, install only if you intend to use the QT GUI.
pacman -S --needed python-qscintilla kdebindings-python
# execute as non root
pip3 install --user python3-xlib
# install AutoKey-Py3 from PyPI or
pip3 install --user autokey-py3
# get the development version from GitHub
pip3 install --user git+https://github.com/autokey-py3/autokey

Available via layman, thanks to y2kbadbug.

To install:

layman -a y2kbadbug
emerge --sync
emerge -av autokey-py3
# make sure that autokey is in your search path.
PATH="$HOME/.local/bin/:$PATH" # if installed with the --user option
autokey-gtk # to start with the GTK3 GUI *OR*
autokey-qt # to start with the QT4 GUI

Documentation for new features. For older features, please refer to the original AutoKey's scripting API, wiki and Stack Overflow.

Examples of AutoKey scripts can be found by searching GitHub and reading AutoKey's wiki.

Changes were made to source code to keep the scripting API stable. system.exec_command() returns a string. But if you use functions from the standard library you will have to fix that, as your script runs on a Python 3 interpreter. For example, expect subprocess.check_output() to return a bytes object.

2to3 can be used to do automatically translate source code.

Some guides on porting code to Python 3:

Please do not request support on the issue tracker. Instead, head over to the autokey-users Google Groups forum, or on IRC (#autokey on Freenode).

Bug reports and pull requests are welcome. Please use the GitHub Issue Tracker for bug reports. When reporting a suspected bug, please test against latest git HEAD and make sure to include as much information as possible to expedite troubleshooting and resolution. For example,

  • required: How to reproduce the issue you are experiencing
  • required: The exact version of Autokey that you're using
  • Python tracebacks
  • Verbose logging information obtained by starting the frontend (autokey-gtk or autokey-qt) from terminal with the --verbose option.

Here.

GNU GPL v3.

About

A Python 3 port of AutoKey, a desktop automation utility for Linux and X11.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 99.9%
  • Shell 0.1%