#!/usr/sbin/install-menu
# freedesktop desktop entry spec - directory generation
# http://www.freedesktop.org/Standards/desktop-entry-spec
# Copyright 2004 - Chris Cheney
# Licensed under the GNU General Public License, version 2.

!include menu.h

compat="menu-2"

function DirEntry() =
	"[Desktop Entry]\n"
	"Type=Directory\n"
	"Encoding=UTF-8\n"
	"Name=" title() "\n"
	"GenericName=" title() "\n"
	"Comment=" ifnempty($longtitle,$longtitle) "\n"
	"Icon=" "debian" replacewith(tolower($section),"/","-") "\n";

outputencoding="UTF-8";

supported;
 x11 = ;
 text = ;
endsupported;

startmenu = "";
endmenu = "";
submenutitle = DirEntry();

treewalk = "M";

genmenu = ifempty($command,tolower("debian" replacewith($section,"/ ","-") ".directory"));

rootsection = "";

prerun = "rm -rf " prefix() "/*";

preoutput = "";

rootprefix = "/var/lib/kde/debian-dirs";

userprefix = ".local/share/desktop-directories/kde/debian";
