@William-Santiago-Ortiz-Trejos, for some reason your files with a .ahk extension aren't associated with AutoHotkey. That's supposed to happen when you install it, but maybe an antivirus program blocked it?
1 - Only Foreground Triggers work in a user's regular account - because the background service only runs as root and uses /root/.TRIGGERcmdData.
2 - Root can support both Foreground and Background Triggers - because you can install the background service (see #1), and because you can login as root and run the agent in foreground mode.
3 - But running Triggers as Root will mask/override all the Triggers in your regular account - I wouldn't say mask/override, it's just separate as you covered in #4. Running the agent as root will create another separate computer entry in your account associated with /root/.TRIGGERcmdData. That computer will be named the same initially, but you could rename it.
4 - The exception to (3) is if you can instantiate two "Computers" -- one pointing to Root for the "Background", and a separate "Computer" pointing to your normal Linux account to support the "Foreground" - correct, although as you pointed out in #2, you could also run the foreground agent as root.
You create a separate computer just by running the agent as the other user. If the ~/.TRIGGERcmdData directory doesn't exist, the agent will prompt you for a token, create a computer record in your account, and store the ID for that computer in the computerid.cfg file.
Different Linux accounts could setup different computer records, or you could give everyone sudo access to be able to edit /root/.TRIGGERcmdData/commands.json to run background command via the background agent.
The agent stores the .TRIGGERcmdData directory in the home folder of the user running the agent. The files in that directory are the key point of connection to the mother ship.
@George-Hatzisymeon, sorry I never responded to this. I just noticed it because someone upvoted it.
I just verified that the offCommand commands.json value is supported in the current version of the Raspberry Pi agent. If you were using that version and it didn't work, then maybe you were missing this part:
Here's an example entry I just tested. It turns my led strip off if the parameter was off, and if the parameter was on, it turns the strip on and makes the leds green.
@Russ Thanks for the clarification. That was my understanding as well - to share TRIGGERcmd for all, either everybody has to use Voice Match or nobody can use it. Unfortunately, the children really want to use the Voice Match (required to teach Google Home important things such as names of our cats etc) while both me and my wife are strictly against Voice Match for us. That means that the children could share TriggerCMD but no solution for the adults. And we'd need TriggerCNS exactly mainly for the adults...
I understand it's a relatively specific situation though, so probably no solution will be available. I was hoping for something similar to Spotify (that works also for non-VoiceMatch members of the household) but I understand it may be difficult to achieve. Thanks for your efforts anyway!
Got it. Looks like you already set that up for me .. as I could see my laptop on the default computer field .. and it is working ! Thank you!
P.S: Is there a location on this forum or site for "How-to's" / Knowledge base - for people to find such information there .. if yes, please direct me to the same, if not, might be a good idea to create one :)
@pico, that's interesting. I'll experiment with that. I hope it works. Thanks for the suggestion.
EDIT: I worked on it for a while and didn't get it working. I couldn't get it to add the Login item while it's quarantined. I think that's a mac security feature for apps downloaded outside of the app store.
I was facing the same problem, but solved while writing this:
If I use the old skill and say "ask trigger CMD to run terço" it works perfect, also works from pressing "trigger" in the website.
If I use the new skill and say "turn on terço" it doesn't.
What have I tried:
Disabling and enabling the skills.
Deleting and adding the command again.
Removing and discovering the comands again in Alexa.
Removing and re-installing the triggercmdagent.
Changing voice command.
Only happens to that command, all the other works fine.
This command is a bash script that open a few chrome pages depending on week day.
I'm using Linux (PopOS 20.04).
I'm using it in portuguese.
Then I decide to try changing the Trigger name. I used "batata" (potato in portuguese) and it worked, then I tried "Terço" again and it didn't, then I tried "Terco", it worked. Apparently it is a problem with "ç" in the trigger name (in the voice command is working well). Since english don't have that, it's understandable. It's not a big thing or really a problem, just wanted to inform so if anyone is having the same problem, try that.
Before I followed the instructions above for sharing my computer with my wife (creating a triggercmd account for her and sharing my computer), I had tried to add her to MY triggercmd account by going on HER phone to HOME / SETUP DEVICE / WORKS WITH GOOGLE and linked to TriggerCMD Smart Home, which it accepted. But after following Russ' process for sharing the computer, neither of us could use Google to turn stuff on or off.
What I had to do is DISCONNECT TriggerCMD Smart Home on HER phone, then reconnect it so it picked up her new triggercmd.com account. You cannot have two people trying to access the same account.
Problem solved and now we both can talk to Google to turn lights on and off.
Thanks Russ for working with me on this...
EDIT: I see that Russ also posted that we solved this! We must have been typing at the same time...