Sunday, July 15, 2018

shell - is there a way to run *.sh file by just touching it in a file manager?


I mean like it is when user opens an image file a pane opens where user can select app for given type. But when I'm clicking on *.sh file the first option that shows up is to open as text/audio/video/image and when I'm choosing to open it as text there is no terminal app in the list. I've installed Xposed framework but this app only allows to remove some of the apps from the list but I cannot find an option to add a terminal to *.sh file as allowed app.


What I mean is it to be like on desktop operating systems where a console shows up and prints and executes all the commands in file.


Now what I do is:
1. open *.sh file in text editor.
2. select all the code
3. copy to clipboard
4. open terminal app
5. paste code into terminal

6. don't forget to press enter to execute last line of the text that was pasted




No comments:

Post a Comment

samsung galaxy s 2 - Cannot restore Kies backup after firmware upgrade

I backed up my Samsung Galaxy S2 on Kies before updating to Ice Cream Sandwich. After the upgrade I tried to restore, but the restore fails ...