If you're going to work with AutoHotKey scripts, I recommend that you download and install Sublime Text 3, which is an excellent editor for all sorts of languages, including AutoHotKey .AHK files. To get the most out of Sublime Text 3 when editing AHK files:
-
Install Sublime Text Package Control, then,
-
Install and Set Up the AutoHotKey Package the easy way:
- Enter the Sublime Text command palette by pressing Ctrl + Shift + P or by navigating to Preferences > Packages Control
- In the input field, type
install
and using your directional keys (up/down), highlight Package Control: Install Package and press Enter - Now type
autohotkey
, and when all the results are filtered to just the one AutoHotKey package and it is highlighted, press Enter. This will install the AutoHotKey package. - Once the AutoHotKey Package for Sublime Text is installed, we're going to need to edit the User Preferences File for AutoHotkey. In Sublime Text, navigate to Preferences > Package Settings > AutoHotKey then click on to open AutoHotKey Settings - User.
- Assuming AutoHotKey installed to C:\Program Files (x86)\ on your computer, paste the following code into the newly opened file (which should have the filename AutoHotKey.sublime-settings) and then save the file:
{ "AutoHotKeyExePath": { "default": "C:\\Program Files (x86)\\AutoHotkey\\AutoHotkey.exe" }, "Ahk2ExePath": { "default": "C:\\Program Files (x86)\\AutoHotkey\\Compiler\\Ahk2Exe.exe" } }
Once you've completed all these steps, you'll have the ability to Run your AutoHotKey Scripts directly from within Sublime Text by pulling up Sublime Text's command pallete by pressing Ctrl + Shift + P and then selecting AutoHotKey - Run from the list (either by searching for AutoHotKey
or navigating down the commands list). You'll also have the ability to compile executable (.exe) files from the Command Pallete as well by pulling it up and then selecting AutoHotKey - Compile. Nifty Stuff.
Bookmarked these instructions for later- thank you!
I have always used SciTEforAutoHotkey, but it hasn't been updated in a long time, and can be difficult to install on new machines. Can you compare Sublime to SciTEforAutoHotkey? Just wondering what I might be missing out on...