#!/bin/sh

# kkatarn, 2016

XDG_MENU="xdg_menu"

_XDG_MENU=`which ${XDG_MENU} 2>/dev/null`

if [ -n "${_XDG_MENU}" -a -x "${_XDG_MENU}" ]; then
	${_XDG_MENU} | sed -E \
		-e 's/https?:\/\/.*/"&"/' -e 's/""/"/g' -e 's/xterm/sakura/'
else
	echo "\"OOPS\" MENU"
	echo "  \"Install appropriate xdg-menu and reflect its name (currently: ${XDG_MENU}) in $0\" EXEC sakura"
	echo "\"OOPS\" END"
fi

