Rapidweather
Group: Members
Posts: 375
Joined: Jan. 2004 |
|
Posted: Nov. 09 2004,00:43 |
|
I am using the opera.uci and the firefox.uci. --- When I do "df" in an rxvt, I discovered that they are now part of the filesystem, and so I decided to write a little script, accessed via the menu, to unload them if I want to play music cd's for a while. ---
Code Sample | #!/bin/bash # # closeuci, version 0.1 # For Rapidweather Remaster of DSL Linux. # file location, /home/dsl/.fluxbox/closeuci # unmount opera.uci and firefox.uci # If you have more .uci's, modify this script. # these .uci's are in /optional in the cdrom # you mastered them in the DSL cd # made part of the filesystem via mydslgui # This script is accessed via menu item: # Menu - > Apps - > Tools - > Unlock CD Drawer. # unmount any of these, mounted or not. sudo umount /mnt/cdrom/optional/firefox.uci sudo umount /mnt/cdrom/optional/opera.uci # now that all uci's are unmounted, print this: echo " All uci's have been unmounted from the filesystem." # Now unmount the cdrom drive, so we can open the drawer. sudo umount /mnt/auto/cdrom # now that the cdrom drive is unmounted, print this: echo "The cdrom drive is unmounted, the drawer can be opened" # None of this could be seen in the GUI, so let Dillo tell it. # You need to make this little html page for Dillo to use: dillo -f /home/dsl/html/cdrom_open.html &>/dev/null & # end closeuci exit 0
|
--- Here is the menu item:
Code Sample | [submenu] (Tools) {} [exec] (myDSL Click and Load){mydslgui.sh} [exec] (Unlock CD Drawer) {/home/dsl/closeuci} [exec] (Net MAN) { rxvt -rv -T "Internet MAN" -e /usr/local/bin/getman} |
--- Notice that I put it next to the MyDSL Click and Load. Also, one could simply run this in an rxvt, and not have the fancy Dillo message, with this html:
Code Sample | <html><head><title>cdrom drive now open</title> <body bgcolor="#c0c0c0"> <center> <br><br> <hr width="440" size="4" align="center"><br> <font color="#000000"> <table border="2" bgcolor="#dcdcdc" width="95%" cellspacing="3" cellpadding="3"> <tbody> <tr><td align="center" bgcolor="#eeeeee"><p> <font color="BLACK"><h3> You may now open the CDROM<font color="BLACK"> drive drawer and remove the CD.</p> <p>The CDROM drive may now be used to play music cd's, for instance. </p> <p>Earlier in this session, you loaded either Firefox or Opera<br> using the MyDSL Click and Load GUI, <br> and the CDROM drive drawer was locked. </font></h3></p> <p><B><font color="BLACK">If you wish to use either Firefox or Opera again, you will need <br> to replace the DSL cdrom in the drawer, and run the MyDSL Click and Load GUI. </font></B></p> <h3>For more information, look at the<A HREF="getting_started.html"> Getting Started Guide.</a></h3><br><br> <p>The /home/dsl/closeuci script has been made for Rapidweather Remaster Version 0.2.8, and is used to unlock the CDROM drive drawer if MyDSL .uci applications are mastered into the CD, and are loaded into the system using the MyDSL Click and Load GUI. The cdrom drive drawer is locked by the MyDSL Click and Load GUI when these apps are loaded. The closeuci script unloads the Firefox and Opera uci's and unlocks the cdrom drive drawer. </p> <br><br> </td></tr></tbody></table> <br> <hr width="440" size="4" align="center"> <br><br> </center></body></html>
|
--- All this has a limited usefulness in that only a few master in the MyDSL applications, and only the .uci's are affected. I have a bunch of Dock Apps in the root of the CD, and in /optional I have Gimp 1.2 and Abiword, both .dsl's and Opera and Firefox, the offending .uci's. --- The location of the closeuci is given in the script, and I "chmod +x closeuci" and also chgrp to staff and chown to dsl, then copy it over to my /etc/skel for inclusion in the next build. Same thing with the menu item, and the html. --- The DSL development team is invited to rewrite this script to a nicer form, and use it if you want or need it. It's possible to include this in the mydslgui.pl script, to completely unload the .uci applications, to allow the cdrom drive, hard drive partition, or pen drive to be unmounted. Everyone would have to think about why this might need to be done. I do know that a "toram" boot option is necessary to be able to get a music cd in the drive, without it, one cannot. With the addition of the very useful and fast .uci's into the cd, we have another way where the cd drive can get locked. ---
-------------- Rapidweather Remaster of DSL: http://www.angelfire.com/ms/telegram/getting_started.html Rapidweather Remaster of Knoppix Linux: http://www.geocities.com/rapidweather/getting_started.html Screenshots: http://www.rapidweather.com/linuxcdsales.html
|