View previous topic :: View next topic |
Author |
Message |
percy_vere_uk Apprentice
Joined: 13 Dec 2008 Posts: 210 Location: Dorset UK
|
Posted: Mon Aug 25, 2014 12:21 pm Post subject: [solved] Trying to set default editor. |
|
|
Hi
I am using gentoo_64bit with an xfce4 desktop and have been trying to set gedit as the system wide default editor.
I have set the default editor using eselect and 'eselect editor show' gives /usr/bin/gedit both in both a terminal and a root terminal.
This works fine and I get gedit each time I open a file as an ordinary user.
But as root I keep getting 'LibreOffic Writer'as the editor.
Any help would be appreciated.
percy
Last edited by percy_vere_uk on Thu Aug 28, 2014 12:33 pm; edited 1 time in total |
|
Back to top |
|
|
John R. Graham Administrator
Joined: 08 Mar 2005 Posts: 10589 Location: Somewhere over Atlanta, Georgia
|
Posted: Mon Aug 25, 2014 9:43 pm Post subject: |
|
|
What doesprint, both for a regular user and for root?
Also, could you clarity whether you're seeing anomalies when editing files within Xfce, or are you seeing the Gentoo tools (e.g., etc-update, dispatch-conf) using an editor other than that specified by "eselect editor".
- John _________________ I can confirm that I have received between 0 and 499 National Security Letters. |
|
Back to top |
|
|
VoidMage Watchman
Joined: 14 Oct 2006 Posts: 6196
|
Posted: Mon Aug 25, 2014 11:12 pm Post subject: |
|
|
More exactly, elaborate what does percy_vere_uk wrote: | But as root I keep getting 'LibreOffic Writer'as the editor. | mean for you, cause if that's actually mimetype problem, the solution lies in a completely different direction. |
|
Back to top |
|
|
percy_vere_uk Apprentice
Joined: 13 Dec 2008 Posts: 210 Location: Dorset UK
|
Posted: Tue Aug 26, 2014 12:44 pm Post subject: |
|
|
John R. Graham
Code: | $ echo $EDITOR /usr/bin/gedit
# echo $EDITOR /usr/bin/gedit |
The only anomaly I have found when editing files is the one I have mentioned.
VoidMage
"But as root I keep getting 'LibreOffic Writer'as the editor."
This means that if I click on a text file as root I get 'LibreOffic Writer' come up as the editor.
I can select gedit by right clicking on the text file it but this action is only required when root.
percy |
|
Back to top |
|
|
Roman_Gruber Advocate
Joined: 03 Oct 2006 Posts: 3846 Location: Austro Bavaria
|
Posted: Tue Aug 26, 2014 3:16 pm Post subject: |
|
|
check your home directory of root, that is usually /root for some hidden files starting with a dot. If you are nasty and do not care for any settings for user root you can even delete those dot files in the folder root, but I do not recommend it. |
|
Back to top |
|
|
percy_vere_uk Apprentice
Joined: 13 Dec 2008 Posts: 210 Location: Dorset UK
|
Posted: Wed Aug 27, 2014 1:43 pm Post subject: |
|
|
tw04l124
I have looked in the /root hidden files and cannot see anything referring to 'LibreOffic Writer'as the editor." |
|
Back to top |
|
|
John R. Graham Administrator
Joined: 08 Mar 2005 Posts: 10589 Location: Somewhere over Atlanta, Georgia
|
Posted: Wed Aug 27, 2014 1:56 pm Post subject: |
|
|
See the very first result from Googling "Setting Default Editor in Xfce". Does that work for you?
The environment variables manipulated by "eselect editor" are not a desktop mechanism and it often requires a desktop-specific mechanism to effect such changes.
Just as an aside, it's considered bad form (because of security risks) to run full-up desktop environments as root.
- John _________________ I can confirm that I have received between 0 and 499 National Security Letters. |
|
Back to top |
|
|
percy_vere_uk Apprentice
Joined: 13 Dec 2008 Posts: 210 Location: Dorset UK
|
Posted: Thu Aug 28, 2014 12:32 pm Post subject: |
|
|
John R. Graham
Thank you.
It was so simple in the end, I think I must have tried everything but!
Code: | Right click on a root text file select properties then open with gedit
I only had to do this once now all text files in /root open with gedit. |
Thanks for all your input on this folks.
percy |
|
Back to top |
|
|
|