Xfce Forum

Sub domains
 

You are not logged in.

#1 2019-12-10 17:20:54

rayandrews
Member
From: Vancouver B.C. Canada
Registered: 2011-12-30
Posts: 179

thunar always opens to root directory

Launched by typing 'thunar' at the command line, it always opens in the current directory and in the current terminal just as one might expect, but when launched from an icon, it always opens to the root directory and often on another desktop.  Can this be fixed?  I've tried every combination of possible settings that I can think of. "thunar $PWD" throws an error if in the icon properties, but works fine from the command line.

Offline

#2 2019-12-11 00:54:02

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,023

Re: thunar always opens to root directory

rayandrews wrote:

but when launched from an icon,

Do you mean a desktop icon or a menu icon? If select to edit or view the properties of the icon, what is the command that is being executed?

it always opens to the root directory

do you mean "/" or "/root"?

and often on another desktop

Do you mean another workspace? Are you running something like devilspie?

I've tried every combination of possible settings that I can think of. "thunar $PWD" throws an error if in the icon properties

You need to specify the actual path. The icon file parser is a very minimal shell. for example:

thunar /home/toz

Can you also post back:

ps -ef | grep -i thunar

...perhaps the daemon is running as root.


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#3 2019-12-11 02:14:46

rayandrews
Member
From: Vancouver B.C. Canada
Registered: 2011-12-30
Posts: 179

Re: thunar always opens to root directory

ToZ wrote:
rayandrews wrote:

but when launched from an icon,

Do you mean a desktop icon or a menu icon?

Icons along the top bar. 

If select to edit or view the properties of the icon, what is the command that is being executed?

Just "thunar" but I also tried "thunar $PWD" and a few other things.

it always opens to the root directory

do you mean "/" or "/root"?

"/"

and often on another desktop

Do you mean another workspace? Are you running something like devilspie?

No devilspie, I think this is 'workspace' ... you get several of them up on the top bar, I have six, IIRC four is the default.

I've tried every combination of possible settings that I can think of. "thunar $PWD" throws an error if in the icon properties

You need to specify the actual path.

That's the thing, I want it to open in the current directory on the active terminal.  Again it works fine if I type 'thunar' on the command line but not using the top-bar icon.

Can you also post back:

ps -ef | grep -i thunar

...perhaps the daemon is running as root.

Ah!  Yes, I do run as root all the time.  I know were not suposta, but I am always root.  Always.

Offline

#4 2019-12-11 03:31:54

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,023

Re: thunar always opens to root directory

rayandrews wrote:

Ah!  Yes, I do run as root all the time.  I know were not suposta, but I am always root.  Always.

I'm mis-understanding something here. If you always run as root, why would you expect that thunar wouldn't open in root's home directory? Where do you expect it will open?


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#5 2019-12-11 14:41:01

rayandrews
Member
From: Vancouver B.C. Canada
Registered: 2011-12-30
Posts: 179

Re: thunar always opens to root directory

ToZ wrote:
rayandrews wrote:

Ah!  Yes, I do run as root all the time.  I know were not suposta, but I am always root.  Always.

I'm mis-understanding something here. If you always run as root, why would you expect that thunar wouldn't open in root's home directory? Where do you expect it will open?

In the current directory in the active terminal window just as if I'd typed 'thunar' at CLI in that terminal.  I suppose it's not obvious that when thunar is launched from the menu bar (top bar, whatever it's called) would want to be linked to the active terminal -- if there even is one -- cuz you might start it while some other application is active, like a browser or something.  But I almost always start it while I'm looking at a terminal and I always want it to start in the current directory on that terminal.  Reason being that I'm looking at a 'ls' of the contents and they need a bit of cleaning up so I want thunar for some housekeeping.  Even as I type this I'm starting to think that what I want isn't obviously the right thing, still it would be nice to have some way of making it happen.  Again, I can always just start it from the command line which always opens at the current directory so I'm not hard done by.

Offline

#6 2019-12-11 14:48:49

ToZ
Administrator
From: Canada
Registered: 2011-06-02
Posts: 11,023

Re: thunar always opens to root directory

rayandrews wrote:

In the current directory in the active terminal window just as if I'd typed 'thunar' at CLI in that terminal.  I suppose it's not obvious that when thunar is launched from the menu bar (top bar, whatever it's called) would want to be linked to the active terminal

Yeah, this is the issue. Thunar (when launched via an icon or .desktop file) won't know the current directory of the terminal window to start there.


Please remember to mark your thread [SOLVED] to make it easier for others to find
--- How To Ask For Help | FAQ | Developer Wiki  |  Community | Contribute ---

Offline

#7 2019-12-11 15:43:37

rayandrews
Member
From: Vancouver B.C. Canada
Registered: 2011-12-30
Posts: 179

Re: thunar always opens to root directory

ToZ wrote:
rayandrews wrote:

In the current directory in the active terminal window just as if I'd typed 'thunar' at CLI in that terminal.  I suppose it's not obvious that when thunar is launched from the menu bar (top bar, whatever it's called) would want to be linked to the active terminal

Yeah, this is the issue. Thunar (when launched via an icon or .desktop file) won't know the current directory of the terminal window to start there.

Could be a nice feature tho.  I saw something on github, couldn't quite figure it out but the guy seemed to have a workaround.

Offline

Board footer

Powered by FluxBB