Quick Launch for simple scripts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi
Try Kerez :
http://david.hautbois.free.fr/joomla/index.php?option=com_content&task=view&id=44&Itemid=43

David.


Julian Toler wrote:
> I am looking for a way to quickly and easily run some simple scripts - 
> the most immediate example is the one line scripts for switching USB 
> host mode on and off:
> echo host > /sys/devices/platform/musb_hdrc/mode
> and
> echo otg > /sys/devices/platform/musb_hdrc/mode
>
> I really don't want to have to fire up the terminal and type these out 
> (and yes I know tab auto complete can speed this up, but this is still 
> not as easy as a menu item!)
>
> I am very much a noob so the following idea may be naive and may be 
> shot down immediately:
> I am assuming I could create a menu item that would run a shell 
> script? Not sure whether these desktop files need to point at 
> executables or whether executable scripts are also OK?
>
> [Desktop Entry]
> Version=1.0
> Encoding=UTF-8 ?? needed?
> Name=MyShinyScript
> Exec=/usr/bin/myscript.sh (or .py or whatever)
> Icon=MyNiceIcon (I can create the correct transparent png)
> Type=Application ?? needed?
> StartupWMClass= ?? needed?
> X-Osso-Type=application/x-executable ?? needed?
> X-Osso-Service=com.nokia. ?? needed?
>
> I am guessing MyShinyScript would look something like:
>
> #!/bin/sh
> echo host > /sys/devices/platform/musb_hdrc/mode
> I know I must make the scripts executable with chmod +x
>
> Of course all this is probably going to be superceded by some kind 
> person who has set up Scratchbox and got their teeth into real 
> programming - a proper Maemo application which installs a simple host 
> mode on-off utility would seem to be a logical development, but in the 
> meanwhile, a scripted hack would be good for me!
>
> Please could somebody tell me if my mad idea will work or whether I 
> should go home and start proper application development?
>
> Cheers
>
> J
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> maemo-users mailing list
> maemo-users at maemo.org
> https://lists.maemo.org/mailman/listinfo/maemo-users
>   


-- 
Web site : http://david.hautbois.free.fr
Tablet users map : http://david.hautbois.free.fr/maps/index.php




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Big List of Linux Books]    

  Powered by Linux