fredvej
Joined: 07 Sep 2006 Posts: 4
|
Posted: Thu Sep 07, 2006 1:05 pm Post subject: sed script to transform fluxbox menu to jwm menu |
|
|
If you put this script :
[code:1]
/\[exec\]/s/\[exec\] *(/<Program label="/
/<Program label="/s/) *{/"> /
/<Program label="/s/}.*/ <\/Program>/
/\[submenu\]/s/\[submenu\] *(/<Menu label="/
/<Menu label="/s/).*/"> /
s/\[end\]/<\/Menu>/
[/code:1]
into a file called flux2jwm.sed and run [code:1] sed -f flux2jwm.sed .fluxbox/menu > jwmenu [/code:1] you can easily edit out the parts that are missing from the jwm menu in RC4 and put it into .jwmrc.
The resulting jwmenu needs some editing, so you probably want to extract the missing entries from .fluxbox/menu first and run sed on the result.
The missing parts in RC4 are
[code:1]
<Program label="Samba"> LinNeighborhood </Program>
<Menu label="Apps">
<Program label="Web browser"> /usr/seamonkey/seamonkey </Program>
<Program label="Email"> /usr/seamonkey/seamonkey -mail </Program>
<Program label="IRC"> /usr/seamonkey/seamonkey -chat </Program>
<Program label="Mplayer"> /usr/bin/gmplayer </Program>
<Program label="WordProcessor"> abiword </Program>
<Program label="Spreadsheet"> gnumeric </Program>
<Program label="FTP Client"> gftp-gtk </Program>
<Program label="IM Client"> gaim </Program>
<Program label="PDF Viewer"> xpdf </Program>
<Menu label="File Manager">
<Program label="emeLFM"> emelfm </Program>
<Program label="emelFM as super-user"> sudo /bin/bash -c emelfm </Program>
</Menu>
<Program label="Xpaint"> /usr/bin/xpaint </Program>
</Menu>
<Menu label="Cups Printing">
<Program label="start"> sudo /etc/init.d/cupsys start </Program>
<Program label="stop"> sudo /etc/init.d/cupsys stop </Program>
<Program label="restart"> sudo /etc/init.d/cupsys restart </Program>
<Program label="reload"> sudo /etc/init.d/cupsys reload </Program>
<Program label="force-reload"> sudo /etc/init.d/cupsys force-reload </Program>
<Program label="Cups Admin"> /usr/seamonkey/seamonkey http://localhost:631 </Program>
</Menu>
<Program label="Leafpad"> leafpad </Program>
[/code:1]
Put Samba into the Network submenu , Leafpad under Editors and the CUPS menu under System. |
|