[mojosetup] set the working path for the desktop entry
nemoder at gmail.com
Thu Oct 13 16:18:54 EDT 2011
On Thu, Oct 13, 2011 at 6:45 AM, Kristen Eisenberg <
kristen.eisenberg at yahoo.com> wrote:
> When clicking on the icon in the application menu, it uses a default
> path. For my program, I need a specific working path.
> There's "Path" variable in .desktop to setup the working path, it works
> if i manually put the path but i find no way to specify the path in the
> Is it possible to add Path in the Setup.DesktopMenuItem?
> I tried to append the Path in the postinstall function but it doesn't work,
> i think the postinstall is called before the creation of the .desktop and
> anyway, it'll require to execute the update of the menu after.
> Have you another idea to do that?
I worked around this with a bit of a hack:
local function postinst()
io.output(MojoSetup.destination .. "/gamestart.sh")
io.write("cd " .. MojoSetup.destination .. "/game/\n")
os.execute("chmod u+x " .. MojoSetup.destination .. "/gamestart.sh")
then for DesktopMenuItem i set:
commandline = "%0/gamestart.sh",
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the mojosetup