Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 06-29-2022, 04:30 PM   #1
Barbas
Enthusiast
Barbas began at the beginning.
 
Posts: 39
Karma: 10
Join Date: Mar 2019
Device: Kindle 10th (2019)
Launch KUAL extension from within KOreader

Hello there,

as the title implies, I'd like to launch a specific KUAL extension (MailPush) directly from KOreader on a jailbroken Kidle Touch.

I don't know if it's the right forum, if not, please excuse me.

Thanks in advance.
Barbas is offline   Reply With Quote
Old 06-29-2022, 04:43 PM   #2
shamanNS
Wizard
shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.
 
Posts: 1,108
Karma: 12000222
Join Date: Feb 2010
Location: Serbia
Device: Kindle PW5, Kobo Libra 2, Kindle PW1
At the very least you should be able to manually run the script that KUAL button runs (check the menu.json content for that extension, the "action" value ) from KOReader's built-in Terminal Emulator? Maybe create an alias for that so you have to type less?
I'm just guessing though... Never tested something like that.

Last edited by shamanNS; 06-29-2022 at 04:45 PM.
shamanNS is offline   Reply With Quote
Advert
Old 07-02-2022, 07:09 AM   #3
Barbas
Enthusiast
Barbas began at the beginning.
 
Posts: 39
Karma: 10
Join Date: Mar 2019
Device: Kindle 10th (2019)
Quote:
Originally Posted by shamanNS View Post
At the very least you should be able to manually run the script that KUAL button runs (check the menu.json content for that extension, the "action" value ) from KOReader's built-in Terminal Emulator? Maybe create an alias for that so you have to type less?
I'm just guessing though... Never tested something like that.
Thank you, the idea works. I was able to launch the .sh script from the command line. What I couldn't do, though, is to figure out how the aliases work. I created an 'aliases' file in the '/script' directory using the Linux syntax, but It didn't work.

Anybody can help? TIA!
Barbas is offline   Reply With Quote
Old 07-02-2022, 07:42 AM   #4
shamanNS
Wizard
shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.shamanNS ought to be getting tired of karma fortunes by now.
 
Posts: 1,108
Karma: 12000222
Join Date: Feb 2010
Location: Serbia
Device: Kindle PW5, Kobo Libra 2, Kindle PW1
Quote:
Originally Posted by KOReader github

User scripts may be placed in the koterm.koplugin/scripts/ folder, aliases can be put in the file aliases and startup command in the file profile.user in that folder.
Quoted from here:

https://github.com/koreader/koreader...sue-1097206917

Current version of KOReader has "terminal.koplugin" folder so try there?

Anyways, you probably have a better chance of getting some useful information if you ask in KOReader thread?

https://www.mobileread.com/forums/sh...d.php?t=270835
There you could maybe even check if there is any interest for some of KOReader developers to try and implement a solution that would parse KUAL's extensions folder and from that create some kind of "inline" UI submenu for running those scripts / extensions from within KOReader.

Or get info if there is a way to create a plugin or whatever to create UI element with static list of scripts / actions / commands.

EDIT: Ok, I've tested with KOReader for Android and creating aliases works. Check the env for a location of "TERMINAL_DATA" variable to find the location of /scripts subfolder.

Click image for larger version

Name:	IMG_20220702_141237.jpg
Views:	398
Size:	37.3 KB
ID:	194693

Click image for larger version

Name:	IMG_20220702_141337.jpg
Views:	354
Size:	34.2 KB
ID:	194694

Click image for larger version

Name:	IMG_20220702_141400.jpg
Views:	345
Size:	41.5 KB
ID:	194695

Click image for larger version

Name:	Screenshot_2022-07-02-14-10-30-886_org.koreader.launcher.jpg
Views:	371
Size:	243.7 KB
ID:	194696

Last edited by shamanNS; 07-02-2022 at 08:19 AM.
shamanNS is offline   Reply With Quote
Old 07-09-2022, 04:21 PM   #5
Barbas
Enthusiast
Barbas began at the beginning.
 
Posts: 39
Karma: 10
Join Date: Mar 2019
Device: Kindle 10th (2019)
Thanks a lot for your help.

I think I've found a simpler way. From within KOreader terminal plugin:

1. Tap the "hamburger" icon (see first enclosed picture)

2. enter your command and the name of the alias (second picture);

3. execute your alias (third picture).

Easy!



Quote:
Originally Posted by shamanNS View Post
Quoted from here:

https://github.com/koreader/koreader...sue-1097206917

Current version of KOReader has "terminal.koplugin" folder so try there?

Anyways, you probably have a better chance of getting some useful information if you ask in KOReader thread?

https://www.mobileread.com/forums/sh...d.php?t=270835
There you could maybe even check if there is any interest for some of KOReader developers to try and implement a solution that would parse KUAL's extensions folder and from that create some kind of "inline" UI submenu for running those scripts / extensions from within KOReader.

Or get info if there is a way to create a plugin or whatever to create UI element with static list of scripts / actions / commands.

EDIT: Ok, I've tested with KOReader for Android and creating aliases works. Check the env for a location of "TERMINAL_DATA" variable to find the location of /scripts subfolder.

Attachment 194693

Attachment 194694

Attachment 194695

Attachment 194696
Barbas is offline   Reply With Quote
Advert
Old 07-10-2022, 04:36 PM   #6
Barbas
Enthusiast
Barbas began at the beginning.
 
Posts: 39
Karma: 10
Join Date: Mar 2019
Device: Kindle 10th (2019)
Here are the pictures:

#1: https://photos.app.goo.gl/fKMcZjLXGdUpZrvdA

#2: https://photos.app.goo.gl/cdZcxwNX2VtQuSjWA

#3: https://photos.app.goo.gl/K6GkoFEPccVzGSX47
Barbas is offline   Reply With Quote
Old 01-16-2023, 07:33 PM   #7
xmarst
Junior Member
xmarst began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Jan 2023
Device: Kindle Touch
Hey, sorry for reviving an old thread, but I was trying to do the same thing, running the sh file from the terminal did show the fetching dialogue, even the operation success one, yet, I couldn't find the file i have sent, i would love to see how you entered your command, the links you sent only lead me to a blank album, maybe you removed the photos or something, the main thing i need is the command calling the sh file.
xmarst is offline   Reply With Quote
Old 01-17-2023, 10:04 AM   #8
guoyongzhi
Member
guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.guoyongzhi could sell banana peel slippers to a Deveel.
 
Posts: 22
Karma: 3094
Join Date: Sep 2021
Device: KOA2
https://www.mobileread.com/forums/sh...0&postcount=42
cd /mnt/us/extensions/MailPush; ./mailpush.sh python3 -u src/mailpush.py
Is this useful?

Since "the terminal did show the fetching dialogue", you can find the file path in the terminal. It is something like "Save it to /mnt/us/xxxxxx". And if the MailPush is version v1.4 or above, you can check the file path history in KUAL menu with the button "View results".

Last edited by guoyongzhi; 01-17-2023 at 10:14 AM.
guoyongzhi is offline   Reply With Quote
Old 01-17-2023, 11:57 AM   #9
xmarst
Junior Member
xmarst began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Jan 2023
Device: Kindle Touch
Talking

Quote:
Originally Posted by guoyongzhi View Post
https://www.mobileread.com/forums/sh...0&postcount=42
cd /mnt/us/extensions/MailPush; ./mailpush.sh python3 -u src/mailpush.py
Is this useful?

Since "the terminal did show the fetching dialogue", you can find the file path in the terminal. It is something like "Save it to /mnt/us/xxxxxx". And if the MailPush is version v1.4 or above, you can check the file path history in KUAL menu with the button "View results".
Thanks! It does work, i am not that familiar with the syntax, i forgot to put the semicolon in the alias, the terminal did show me the dialog because i was just opening the script without any parameter, i was tired, and quite didn't know what i was doing, i am not that good with these things, thanks again
xmarst is offline   Reply With Quote
Old 01-18-2023, 02:59 AM   #10
hius07
Wizard
hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.hius07 ought to be getting tired of karma fortunes by now.
 
Posts: 1,167
Karma: 3592925
Join Date: Sep 2014
Location: Ukraine
Device: Kindle
You can also try to long-press a sh file in the KOReader file browser and select "Execute shell script".
hius07 is offline   Reply With Quote
Old 01-18-2023, 12:37 PM   #11
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,506
Karma: 26047190
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
Quote:
Originally Posted by hius07 View Post
You can also try to long-press a sh file in the KOReader file browser and select "Execute shell script".
This also works from the Favorites screen (which is... my only use of that feature: to put scripts in (especially since they usually live outside of my library) ).
NiLuJe is offline   Reply With Quote
Reply

Tags
mailpush koreader kual

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PW4 SimpleReboot (KUAL Extension) Kusuri Kindle Developer's Corner 3 06-28-2022 11:34 AM
PW [KUAL] Yet another clock extension MrTick Kindle Developer's Corner 3 10-21-2019 03:06 PM
Frontlight Adjust KUAL+ extension j.p.s Kindle Developer's Corner 1 01-07-2018 06:51 PM
xmahjongg for Kindle as Kual extension Hanspeter Kindle Developer's Corner 86 12-02-2016 07:06 PM
kual extension to open a book shoelesshunter Kindle Developer's Corner 14 08-16-2016 12:30 PM


All times are GMT -4. The time now is 05:44 AM.


MobileRead.com is a privately owned, operated and funded community.