[BUG]: Autohotkey Not Getting Found Even When Installed #362

Closed
opened 2026-01-05 14:50:00 +01:00 by adam · 1 comment
Owner

Originally created by @ksharizard on GitHub (May 1, 2024).

Describe the bug
Whenever I run komorebic start --ahk, i get the following error: Error: could not find autohotkey, please make sure it is installed before using the --ahk flag. I have autohotkey v2 installed through winget so this error should not be present.

To Reproduce
Steps to reproduce the behavior:

  1. Install autohotkey through the official website or winget
  2. Run komorebic start --ahk
  3. See bug

Expected behavior
Autohotkey should be located.

Screenshots and Videos
Add screenshots and videos to help explain your problem.

Operating System

OS Name:                   Microsoft Windows 10 Pro
OS Version:                10.0.19045 N/A Build 19045

komorebic check Output

No KOMOREBI_CONFIG_HOME detected, defaulting to C:\Users\ghoul

Looking for configuration files in C:\Users\ghoul

Found komorebi.json; this file can be passed to the start command with the --config flag

Application specific configuration file path 'C:/Users/ghoul/applications.yaml'
does not exist. Try running 'komorebic fetch-asc'

No ~/.config/whkdrc found; you may not be able to control komorebi with your keyboard

Additional context
I believe the problem is caused due to autohotkey not being in path. Some solutions I can propose is

  1. Adding autohotkey to path
  2. Hardcoding the location of autohotkey
  3. Using app paths to get the location of autohotkey [Ex. [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\AutoHotkey.exe]]
Originally created by @ksharizard on GitHub (May 1, 2024). **Describe the bug** Whenever I run ```komorebic start --ahk```, i get the following error: ```Error: could not find autohotkey, please make sure it is installed before using the --ahk flag```. I have autohotkey v2 installed through winget so this error should not be present. **To Reproduce** Steps to reproduce the behavior: 1. Install autohotkey through the official website or winget 2. Run komorebic start --ahk 3. See bug **Expected behavior** Autohotkey should be located. **Screenshots and Videos** Add screenshots and videos to help explain your problem. **Operating System** ``` OS Name: Microsoft Windows 10 Pro OS Version: 10.0.19045 N/A Build 19045 ``` **`komorebic check` Output** ``` No KOMOREBI_CONFIG_HOME detected, defaulting to C:\Users\ghoul Looking for configuration files in C:\Users\ghoul Found komorebi.json; this file can be passed to the start command with the --config flag Application specific configuration file path 'C:/Users/ghoul/applications.yaml' does not exist. Try running 'komorebic fetch-asc' No ~/.config/whkdrc found; you may not be able to control komorebi with your keyboard ``` **Additional context** I believe the problem is caused due to autohotkey not being in path. Some solutions I can propose is 1. Adding autohotkey to path 2. Hardcoding the location of autohotkey 3. Using app paths to get the location of autohotkey [Ex. [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\AutoHotkey.exe]]
adam added the bug label 2026-01-05 14:50:00 +01:00
adam closed this issue 2026-01-05 14:50:01 +01:00
Author
Owner

@LGUG2Z commented on GitHub (May 1, 2024):

You can specify an override for the exe file name using the KOMOREBI_AHK_EXE environment variable.

Unfortunately the casing issue with the AHK exe on different distribution platforms has been an issue for a long time. I think someone should raise an issue on the AHK tracker to standardize the casing of the exes that are distributed through scoop, winget, chocolatey etc.

@LGUG2Z commented on GitHub (May 1, 2024): You can specify an override for the exe file name using the [`KOMOREBI_AHK_EXE`](https://github.com/LGUG2Z/komorebi/commit/710a8d76ea590ed205864d1687adb3694838435c#diff-669eb0fce6967fea49390c1ec784c3c4df5a95f95853066d97720a33947503ccR1407) environment variable. Unfortunately the casing issue with the AHK exe on different distribution platforms has been an issue for a long time. I think someone should raise an issue on the AHK tracker to standardize the casing of the exes that are distributed through `scoop`, `winget`, `chocolatey` etc.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/komorebi#362