#!/bin/sh # created by daelstorm # First off, this is insane. # Hey, I didn't have a clue what i was doing when i started.. # Thanks to this page, http://www.grymoire.com/Unix/Sed.html i discovered @ and \1 # and finally finished this Fluxbox -> Openbox3 menu converter # it doesn't parse anything, so you may have to clean up stuff.. anyway, this will save you time, # if nothing else. sed 's/\[begin\] (\(.*\))/\n\n\n/g s/\[workspaces\] *(\(.*\))//g s/\[config\] *(\(.*\))//g s/\[stylesdir\] *(\(.*\))//g s/\[restart\] (\(.*\)) {\(.*\)}/\2<\/execute> <\/action><\/item>/g s/\[restart\] (\(.*\))/ <\/item>/g s/\[nop\] (.*)//g s/{}//g s/\[exit\] (\(.*\))/<\/item>/g s/\[submenu\] (\(.*\))//g s/\[reconfig\] (\(.*\))/<\/item>/g s/\[exec\] (\(.*\)) {\(.*\)}/\2<\/execute> <\/action><\/item>/g s/\[end\]/<\/menu>/g s/&/and/g' "$@" > openbox-menu.xml && echo "" >> openbox-menu.xml #thanks for cleaning it up, smacklefunky