- AHK can only guess at whether to run a script as V1 or V2.
- The official AHK2 release announcement states that "The Launcher will run the appropriate version of AHK based on its attempt at automatic detection and your settings." (emphasis mine)
- Linux shell scripts typically begin with a shebang line that explicitly states what execution mehtod to use.
- If we add the same kind of shebang to AHK scripts, then we can actively tell AHK which version to use.
- Incidentally, I think the standard shebang symbol #! is directly compatible with AHK syntax.
- The AHK settings can specify whether the shebang will be honored = see dummy screenshot below.
- Any script that has a shebang will be guaranteed to run with the AHK version the author intended.
- Any script without a shebang will remain subject to AHK auto-detection.