Subject: | |
From: | |
Reply To: | |
Date: | Wed, 19 Oct 2011 17:24:55 +0100 |
Content-Type: | TEXT/PLAIN |
Parts/Attachments: |
|
|
On Tue, 18 Oct 2011, Yasha Karant wrote:
> I know how to change the application associated with (opens) a particular
> file type finding an instance of the file type, getting to the preferences
> for that type through the GUI, etc., a very time consuming process.
>
> For each window manager (Gnome, KDE, ... ) is there a systems text file, or,
> in the worst case, a file in each user's directory, that controls this
> association? If so, will the simple editing of this file (these files)
> suffice upon the next startup of the window manager (login by a user)? Do EL
> 5 and EL 6 versions of a window manager use the same configuration file(s) in
> this regard (e.g., has the method to configure Gnome, KDE, etc., change
> between EL 5 and EL 6)?
I've not looked on sl6 but for sl5 the central config is in
/usr/share/applications/defaults.list with user changes stored in
.local/share/applications/defaults.list
The format maps mime-types to .desktop names - ie usually for things in
/usr/share/applications/
Be aware ('cos I wasn't!) that if you manage to break the file then it is
completely ignored which will result in the system picking one of the apps
which has registered for that mime-time in a non-obvious way.
We had installed a 3rd party rpm which had a %post that 'updated' the
defaults.list and added a broken line. It was about 3 years later (long
after the offending package had been replaced by one without that bug)
that we finally worked out why some machines were behaving in an odd way.
On sl5 the defaults.list file is owned by the shared-mime-info package
which is part of freedesktop.org so ought to apply to any window manager
which obeys their spec.
Normally we only worry about Gnome but a quick check with KDE suggests
that it seems to ignore the values (ie it opens a .pdf in KGhostView even
if (say) Adobe Reader has been set as the default for application/pdf...
Or maybe my KDE test setup is broken in some way.
-- Jon
|
|
|