Show '..' (parent) in folder
-
- Site Admin
- Posts: 60599
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: Show '..' (parent) in folder
RSI: yep, been there from too much hi-hat action on the drums. I couldn't hold a beer bottle for 6 months with my right hand.
FAQ | XY News RSS | XY Twitter
-
- Site Admin
- Posts: 60599
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: Show '..' (parent) in folder
You just add an item to the Catalog and put
..
in to the Location field.
Then you have this thing to click on for "go up" (and you don't even have to scroll up the list):
FAQ | XY News RSS | XY Twitter
Re: Show '..' (parent) in folder
Hi,
Not sure if its me but
"tweak ABRelativeToAppPath is set to 1." doesnt seem to work. Both 0 or 1 go to application path.
I did restart the app.
Not sure if its me but
"tweak ABRelativeToAppPath is set to 1." doesnt seem to work. Both 0 or 1 go to application path.
I did restart the app.
Re: Show '..' (parent) in folder
admin wrote: ↑05 May 2022 10:40 Additionally from the next beta onwards you can use..
as location in a Catalog item to go upwards from here:
Code: Select all
* Catalog: A location ".." was by default resolved relative to app path. Nobody needs this. Now it is resolved relative to the current path. Exception: tweak ABRelativeToAppPath is set to 1.
Hi Don
Are you planning to change the behavior of this function as well?
resolvepath("..")
I use it a lot to find the parent folder of XYPlorer because of my folders structure.
.../portable/
.../portable/xyplorer
.../portable/mpv
.../portable/others
For example, in CFA:
Code: Select all
|"MVP|MPV.ico" {:Video}>::run resolvepath("..")."\MPV\mpv.exe --config-dir=".resolvepath("..")."\MPV\mvp ""<curitem>""" ;
Last edited by omid on 05 May 2022 17:20, edited 1 time in total.
-
- Site Admin
- Posts: 60599
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: Show '..' (parent) in folder
No, resolvepath("..") has not and will not be changed. So there is no need for <xyparent>. Right?
FAQ | XY News RSS | XY Twitter
Re: Show '..' (parent) in folder
A bit shorter and easier to read...
Code: Select all
|"MVP|MPV.ico" {:Video}>::$p = resolvepath(".."); run lax("$p\MPV\mpv.exe" --config-dir="$p\MPV\mvp" "<curitem>");
One of my scripts helped you out? Please donate via Paypal
Re: Show '..' (parent) in folder
Thank you highend, as always, I learn a lot from your codeshighend wrote: ↑05 May 2022 17:30 A bit shorter and easier to read...Code: Select all
|"MVP|MPV.ico" {:Video}>::$p = resolvepath(".."); run lax("$p\MPV\mpv.exe" --config-dir="$p\MPV\mvp" "<curitem>");
Re: Show '..' (parent) in folder
If think
<xyparent>
makes total sense. Especially for all the people that store XY in a portable folder (and belonging tools one level above)....One of my scripts helped you out? Please donate via Paypal
-
- Posts: 195
- Joined: 21 Oct 2020 23:33
- Location: Through the Looking-Glass
Re: Show '..' (parent) in folder
I use
One of the selling points on the XY homepage is portability, so having such a variable would be beneficial for the users who use relative paths in order to maintain that portability.
You can never have enough environment variables. Useful for people who need them and unobtrusive for those that don't. Win-win.
<xypath>..\..\when accessing the parent folder where I keep XY. It works fine, but if I could make it more readable with <xyparent> then I'm all for it.
One of the selling points on the XY homepage is portability, so having such a variable would be beneficial for the users who use relative paths in order to maintain that portability.
You can never have enough environment variables. Useful for people who need them and unobtrusive for those that don't. Win-win.
-
- Site Admin
- Posts: 60599
- Joined: 22 May 2004 16:48
- Location: Win8.1 @100%, Win10 @100%
- Contact:
Re: Show '..' (parent) in folder
You should use
I'll add <xyparent>.
<xypath>\..
to go to the parent folder. Your pattern leads to an invalid path that leads to the right goal only through grace. I'll add <xyparent>.
FAQ | XY News RSS | XY Twitter
Re: Show '..' (parent) in folder
Thank you for adding
<xyparent>