Workaround for an annoying Firefox "feature" in *nix
Lennart Sorensen
lsorense-1wCw9BSqJbv44Nm34jS7GywD8/FfD2ys at public.gmane.org
Mon Apr 6 16:31:31 UTC 2009
On Sun, Apr 05, 2009 at 12:49:19AM -0400, Walter Dnes wrote:
> In the old days, we had to manually type in the program name to use
> for "helper applications". Nowadays, Windows and Mac standards seem to
> have taken over. Big brother knows what good for you, and you can only
> use an annoying file-picker dialogue. What's even worse is that the
> dialog *FORCIBLY DE-REFERENCES SYMLINKS*. I download a specific CSV
> file from the web regularly with Firefox. When I first tried
> downloading it, I was asked which program to use. I pointed the file
> picker at /usr/bin/gnumeric which was a symlink that pointed to
> /usr/bin/gnumeric-1.8.3 But because Firefox is so bleeping "user
> friendly", it de-referenced the symlink to /usr/bin/gnumeric-1.8.3
>
> Fast-forward a few weeks. A regular Gentoo update bumps the version
> to gnumeric-1.8.4 and when I tried to download the CSV file, Firefox
> complained that the helper app (/usr/bin/gnumeric-1.8.3) did not exist.
> Well... like... dohhh. I went through the rigamarole with the file
> picker dialogue. And again, it de-referenced the symlink, this time to
> /usr/bin/gnumeric-1.8.4
>
> This annoyed me enough to make me look deeper. With the help of
> Google I found
> https://bugzilla.mozilla.org/show_bug.cgi?query_format=specific&order=relevance+desc&bug_status=__open__&id=176486
> I noticed the rant in comment #46, and threw in my own at #47 and went
> off on a wild hunch to hack around it. My hunch appears to work.
> Here's a quick-n-dirty work-around to the problem...
>
> With the help of "grep -r", I found references to to gnumeric-1.8.4 in
> file mimeTypes.rdf in my user account directory. I...
>
> 1) shut down Firefox
> 2) created a backup of mimeTypes.rdf
> 3) in mimeTypes.rdf manually edited all occurences of
> "/usr/bin/gnumeric-1.8.4" and "/usr/bin/gnumeric-1.8.3" (why was it
> still around?) down to "/usr/bin/gnumeric".
> 4) restarted Firefox
>
> The app associated with CSV files is now simply "gnumeric". Nothing
> has blown up. My only complaint now is that I had to hack my way around
> the bug. I won't know for certain until the next update of gnumeric,
> but I believe I won't have to re-set the helper app for CSV files.
Another solution would be to make gentoo use hardlinks instead of symlinks
in which case firefox et al would have nothing to worry about and nothing
to dereference. Would be more effificient too since you don't have to
constantly dereference symlinks all over the place.
Does make it harder to see what the current version of a tool is using ls.
--
Len Sorensen
--
The Toronto Linux Users Group. Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists
More information about the Legacy
mailing list