GNOME Bugzilla – Bug 91194
Macros should potentially be global, not per-applet
Last modified: 2005-05-15 05:40:45 UTC
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=71489 The macros are pretty hard to set up, and it's unlikely you want them different for two different command line applets
Kevin, what do you think about this ?
Still an issue. Can we have this revised? regs, Chris
Sounds sensible and straightforward
Mark, did you want to fix this?
I've committed this to CVS. I've added a mini-commander-global.schemas.in which gives schemas for /apps/mini-commander/macro_{patterns,commands}. For some reason, schema defaults are still being installed in /apps/panel/.../prefs/macro_{patterns,commands} but I couldn't obviously see why. It could be cache or gconf grabbing things out of my other prefix or a mistake I've made. Mark, Could you perhaps check it over to see if you can see anything obvious?
My guess is that the old schemas are still installed in /apps/mini-commander/prefs/ and so: panel_applet_add_preferences (applet, "/schemas/apps/mini-commander/prefs", NULL); still installs the applyto in /apps/panel (i.e. you wouldn't see this on a clean system) However, we have a problem here. We really should not move around schemas like this because it breaks compatibility. We need the schemas installed in both the new location *and* the old location. The issue is that a GNOME 2.8 user will have applytos in his/her configuration referencing the schemas in /apps/mini-commander/prefs, but when they upgrade their machine to GNOME 2.10 or use that configuration on 2.10 (say using an NFS homedir) these schemas will no longer exist and they won't see the default macros. Attaching an untested patch which should make sure old configurations don't break.
Created attachment 33629 [details] [review] patch
Comment on attachment 33629 [details] [review] patch Mark, did you want to commit this then?
Gee, it sure would be nice if people didn't randomly nuke useful features for the hell of it. I keep 4 separate instances of mini-commander in my panel, with differently-colored backgrounds. One works normally; the other three each have a single macro with a pattern like ^(.*)$, mapped to commands like running a script which obtains the right Kerberos tickets and then opens a terminal running an ssh session to some machine to log in as root. This is extremely useful, but when I upgraded it stopped working thanks to this "improvement". Please fix this so I don't have to keep running an ancient version of this applet forever...
Removing and re-adding the applet seems a lot more common than thinking of the thing you describe... esp. since the default macros are all of the form "keyword: argument" which is intended to lead people to do it that way instead of having a separate applet for each keyword.