With Coreelec you can do “Kodi restart” or “Reboot” when you hit the power-button via GUI.
When I do “Kodi restart” it probably does only a “systemctl restart kodi” (software restart, instead of hardware, which I like if Kodi hangs etc).
Question: Can I do the same via Yatse?
The power button via Yatse is only providing a reboot, no Kodi-restart. Alternatively is it possible to do a Kodi-restart via custom command?
I guess they do it via “systemctl restart kodi”, but I don’t know how to call a sh command via Yatse. Is this possible via custom command? Do I need to create a simple addon and call this? Help would be appreciated!
Interesting that you can remember me. But yes this hearty interaction is always the same <3 …
As already mentioned, they just call it via sh (“systemctl restart kodi”) and I asked here how I can fire this via Yatse… (I would not have asked, if I had found something in the documentation)
Your answer like “read the documentation” was not helpful, but well, I found a solution by myself.
If someone is also interested in this, just create an empty addon and add following line in the default.py:
import os
os.system('systemctl restart kodi')
Via Yatse I used the custom commands with Addons.ExecuteAddon.
If someone is interested in more details, I can put them here as well if needed.
Thanks…
@Tolriq if you have an easier way (e.g. how to call that sh via Yatse, like the original question), I would appreciate if you can share…
Again I know you prefer to always be right and everything but your question is Kodi support material …
Yatse can call Kodi commands via the Custom commands the documentation clearly state what it can call.
What is needed inside Kodi to call a shell script is well inside Kodi. And so outside of Yatse support.
Is there a built in it’s probably in Kodi doc.
Is there other ways it’s probably in Kodi doc.
Is writing an addon working? (So Kodi side) seems it works.
In all cases, Kodi support or Coreelec support would have answered your question…
Ok, then the answer from you that I was looking for was:
“Sorry, sh commands such as ‘systemctl restart kodi’ are not possible to delivery via Yatse to Kodi directly.”
You know, maybe that is “our” problem: Expectations vs Reality, like in a relationship
The answer was I fucking don’t know, ask the people who do But I tried to keep it nice despite history and yet here we are.
When you purchase an universal remote for a TV and want the remote to make the TV do something that you don’t even know if your TV can do it, if you ask the universal remote maker, he will tell you : Ask your TV for the remote code and then you can put it inside the remote… And you would say OK thanks.
And yet here, you are unhappy by the same answer because you know better
You don’t know if your Yatse can fire an sh-command to Kodi? You should know if this is possible or not! This was the question, not more ^^
And your example is not correct! You are in the tunnel, you know Yatse best, the rest of us not! I would expect that NO ONE knows what is the exact potential of Yatse “as an universal remote” (what is possible and what not). Actually this is a compliment, Yatse can do a lot of stuff. Especially if you have handy features like the custom commands (with thousands of possibilities).
As mentioned, I don’t expect to get detailed answers. I just want to get a direct answer to MY question: Can I call sh commands via Yatse → no you cannot. In a perfect world you can extend to: but you could do this or that to reach your goal.
And again you do not read anything that’s wonderful
I DO NOT FUCKING KNOW …
Your question is about Kodi internals. I talk to Kodi external API.
Now since you keep being an asshole let me read the documentation for you since you can’t and do what you should have done. Then I’ll officially stop answering you on this forum since you clearly do not deserve my time.
3 Built-In Commands : Gives you access to all the internals of Kodi as available to skins
You can see Kodi built in information in details at: Kodi Built-In Wiki
System.Exec(exec) Execute shell commands. The full path to the script has to be placed inside the parentheses.
So guess what the documentation have your answer …
Now let’s read the header of that page
THIS PAGE IS OUTDATED:
This page has become too large and complex to maintain by volunteer editors, and has been only sporadically updated over the last few years.
This page may have missing data, and may also shows data that has been deprecated.
Refer to the up to date Doxygen documentation
So no I’m not fucking supposed to know the thousands of commands that Kodi support and the dozens of way to do things there, specially when even the documentation is not up to date. I’m not an encyclopedia, I also support Plex, Emby, Jellyfin …
And yes this was a fucking support question for Kodi. I know you want to answer to argue that you know better, that you don’t need to read the doc or what I write because well you are you and everything. But any more argument here = ban.
Wow… Nice! Obviously we are not compatible by finding the words to address the other one…
You dont have to!
Thanks, your latest answer is (without the NOT-nice words) like I expected a professional answer.
A summary for other users who find this post (which is my accepted answer to this - short but answers everything):
“No it is not possible to execute sh comands via Yatse custom commands, but have a look at our documentation Yatse Custom Commands → 3 Built-In Commands : Gives you access to all the internals of Kodi as available to skins: Kodi Built-In Wiki if something is available for you to achieve your goal.”
I did answer you that if it’s possible in Kodi then it will be possible in Yatse. Then I did gave you the doc that have everything for you to search what is possible inside Kodi.
I’m not your slave, I’m not Kodi support. You had the proper answers from Yatse point of view. The rest is history, you just can’t accept being wrong.
That’s amazing how entitled you think you are. I owe you nothing …
And for the record :
Your answer is a non sense:
It says: No it’s not possible but look here were it’s possible …
So to resume as explained I did not know it was Kodi side information and I’m sorry but no I do not have to do the research for you … Specially after our last encounter.
Anyway I won’t have to deal with you anymore you were warned.
Wow, this thread is unhelpful to the max, even though the answer is so simple:
Kodi has the built-in function System.Exec, which can run scripts, but not accept arguments.
Which means to run a command with arguments, just create a script and call that: