touch mydsl.menu/whatever won't create new itemForum: Apps Topic: touch mydsl.menu/whatever won't create new item started by: nickelplated Posted by nickelplated on Oct. 12 2006,23:06
Man, I seem to have this same problem every time I go to make an extension and can never remember what I do to make it go away. Can somebody help me out here? I create a new file in /tmp/mydsl.menu/ using the format listed [exec] (display name) {command} but it doesn't create a new menu item. I put it into a directory structure of my fully functioning new extension and turn it into a .dsl and it'll even load properly on a vanilla system, but still, it doesn't create a new menu item. Anyone else have a similar issue? Posted by mikshaw on Oct. 13 2006,13:49
It's probably either incorrect file permission/ownership within the extension, or the mydsl system was broken by installing an extension as root.Check the ownership of files in the extension with the command
Most of the files should be owned by root (0/0). Files in /home/dsl, including /home/dsl itself, should be owned by dsl.staff. The file within /tmp/mydsl.menu should be owned by dsl.staff. Check the ownership of the file(s) in /tmp/mydsl.menu in your filesystem. They should all be owned by dsl. If not, do this as root:
Posted by nickelplated on Oct. 14 2006,03:17
Interestingly enough, I've ruled out those as the cause. Permissions are fine, and I'm not root. The program loads though. I even tried to copy one of the menuitems from another extension in there, or edit a pre-existing menuitem, and no matter what I edit it to say, the menu doesn't change. I've made an Icon for it though and that's working fine, which I guess is good enough. By the way, is there some kind of an equivalent to kdialog that's included with fluxbox/busybox, so I can make a little popup dialog box when they click the icon or menu item that'll explain how to configure the program? Posted by ^thehatsrule^ on Oct. 14 2006,04:48
I'd suggest for you to edit one of the menu items from a working extension.I suppose you could use a .lua dialog, or some output it in a terminal program, or dillo/beaver even. To do this, instead of pointing the icon to the program itself, point it to a "wrapper" script. Depending on which way you want to proceed, this script will basically launch your dialog first, before executing the program (I suppose if you use .lua, you can have a nice "OK" button or something...) i.e. this may help...
Posted by mikshaw on Oct. 14 2006,13:28
I forgot another place where file ownership is an issue:/home/dsl/.fluxbox/mydsl.menu This is an include file for /home/dsl/.fluxbox/menu, and must also be owned by dsl. This applies to DSL >=2.3 DSL has xmessage, which is fairly flexible in its use (though a bit fat for what it does), and roberts made a couple of tiny lua scripts called popask.lua and popup.lua: popask.lua
'yes' or Enter prints 1, and 'no' or Esc/close prints nil (although the actual exit code of the app itself is 0). popup.lua
Posted by nickelplated on Oct. 14 2006,16:30
Sweet thanks guys for all the great info, and suggestions.
Posted by humpty on Oct. 16 2006,04:29
man, i used to have the same problem, i can't remember how i used to fix either!it's along shot, but are you using some fancy editor that's screwing things up? Posted by nickelplated on Oct. 16 2006,13:32
Yeah I'm still kinda figuring it out, but leaning toward just using an icon instead, along with a popup notification so users know the service started.I'm using VIM. Posted by nickelplated on Oct. 17 2006,19:25
I don't think I know what this means. Am I supposed to start including the .fluxbox/mydsl.menu file in the extensions now? If I did, wouldn't it overwrite whatever's already in there on the system? I didn't see any mention of anything that relates to this in the wiki, except maybe this single line- "The contents of the menu item are identical to the lines within the fluxbox menu file:" but what exactly am I supposed to do with this fluxbox menu file? I see there are entries in there, and that when I manually edit it and add in the info for my extension that it finally shows up in the menu. So I guess it wasn't a permissions issue, but I still don't know what to do. Am I missing something here? Posted by roberts on Oct. 17 2006,20:29
No. Extensions should not directly reference .fluxbox/mydsl.menu nor .fluxbox/menuIf you have loaded any extension. Then take a look at /tmp/mydsl.menu/ You should see an example. With over 300 some extensions built it should not be that difficult. Your extension menu entry should be placed relative to tmp/mydsl.menu/ The your_extension_base_name must match the extension basename, e.g.., xchat.dsl tmp/mydsl.menu/xchat extension name and thus menu item name must be unique that is why many use the version number as part of the name. Permissions have already been dicussed. The mydsl-load scripts will handle the update to the proper location of mydsl.menu or menu relative to .fluxbox. depending on version of DSL running. Posted by nickelplated on Oct. 17 2006,20:54
Oh, now I see. I've been trying to use a new extension name to differentiate it from the other versions I have on the hard drive, but the menu item name didn't match it. Cool, it's working now. Thanks Roberts.
|