I'm a big fan of AutoIT (https://www.autoitscript.com/).
It means less code but more powerfull standalone programs.
But hey, I want to use it portable, but hey, I made a program for that.
This executable is free to use.
What it does:
Copy the executable in the same directory as where AutoIt exists.
Usually the directory whare AutoIt3.exe resides.
Run the executable and it is done.
What does it do?
It registers AutoIT's location in the registry, that's all.