[9.10x64b1] F7, environment variables not expanded

Bug reports will be moved here when the described bug has been fixed

Moderators: white, Hacker, petermad, Stefan2

User avatar
wanderer
Power Member
Power Member
Posts: 1571
Joined: 2003-03-28, 14:35 UTC
Location: Sol

[9.10x64b1] F7, environment variables not expanded

Post by *wanderer »

F7. I tried to create folder:

%TEMP%\TC\Log

but TC, instead of expanding %TEMP% to C:\Users\<User>\AppData\Local\Temp, it just created a folder %TEMP%\TC\Log in the current folder.
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
sqa_wizard
Power Member
Power Member
Posts: 3854
Joined: 2003-02-06, 11:41 UTC
Location: Germany

Post by *sqa_wizard »

Well, yes that it the way it works - straight forward.
How else do you create a folder with name "%TEMP%" ?
#5767 Personal license
User avatar
wanderer
Power Member
Power Member
Posts: 1571
Joined: 2003-03-28, 14:35 UTC
Location: Sol

Post by *wanderer »

sqa_wizard wrote:Well, yes that it the way it works - straight forward.
How else do you create a folder with name "%TEMP%" ?
Hmmm. A better question might be "how do you "cd" into it". :)

I'm talking about a classic command-prompt "cd" of course.
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
Dalai
Power Member
Power Member
Posts: 9364
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

I think this is intentional, or at least it's not a bug because TC 8.52a behaves the same way.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
User avatar
wanderer
Power Member
Power Member
Posts: 1571
Joined: 2003-03-28, 14:35 UTC
Location: Sol

Post by *wanderer »

Dalai wrote:I think this is intentional, or at least it's not a bug because TC 8.52a behaves the same way.
Yes, it seems so. IMO it would be nice if a simple checkbox existed somewhere left of the "OK" button, to "expand environment variables".
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
Lefteous
Power Member
Power Member
Posts: 9535
Joined: 2003-02-09, 01:18 UTC
Location: Germany
Contact:

Post by *Lefteous »

Hmmm. A better question might be "how do you "cd" into it". Smile

I'm talking about a classic command-prompt "cd" of course.
CD works fine here for these kind of paths.
User avatar
wanderer
Power Member
Power Member
Posts: 1571
Joined: 2003-03-28, 14:35 UTC
Location: Sol

Post by *wanderer »

Lefteous wrote:CD works fine here for these kind of paths.
Yes, in Powershell. The classic command prompt just goes to the TEMP folder.
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
Lefteous
Power Member
Power Member
Posts: 9535
Joined: 2003-02-09, 01:18 UTC
Location: Germany
Contact:

Post by *Lefteous »

Yes, in Powershell. The classic command prompt just goes to the TEMP folder.
I talked about the command-line in TC.
User avatar
wanderer
Power Member
Power Member
Posts: 1571
Joined: 2003-03-28, 14:35 UTC
Location: Sol

Post by *wanderer »

Lefteous wrote:
Yes, in Powershell. The classic command prompt just goes to the TEMP folder.
I talked about the command-line in TC.
Nope. Here it just goes to TEMP folder. Maybe it's an O/S thing or a matter of TC configuration?
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Indeed environment variables cannot currently be used in F7, Shift+F4 etc. I could allow them when using placeholders - either just when prefix < is there, e.g.
<%TEMP%
or in form
<[%temp%]

What do you think?
Author of Total Commander
https://www.ghisler.com
User avatar
wanderer
Power Member
Power Member
Posts: 1571
Joined: 2003-03-28, 14:35 UTC
Location: Sol

Post by *wanderer »

ghisler(Author) wrote:What do you think?
Well, it's a nice solution because the user can select which of the variables he wishes to expand, but with this solution you add an extra thing the user has to remember. If you can also add an on-the-screen hint in the dialog (a label with "use < to expand variables")...
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I could add a sample like [%temp%] to the + button list.
Author of Total Commander
https://www.ghisler.com
User avatar
wanderer
Power Member
Power Member
Posts: 1571
Joined: 2003-03-28, 14:35 UTC
Location: Sol

Post by *wanderer »

ghisler(Author) wrote:I could add a sample like [%temp%] to the + button list.
Yup. That would also not require a translation, right? ;)
- Wanderer -

¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
Normally using latest TC on:
x32: WinXPx32 SP3
x64: Clients/Servers from Win7 to Win11 and Win2K12Srv to Win2K22Srv, mainly Win10 though.
User avatar
sqa_wizard
Power Member
Power Member
Posts: 3854
Joined: 2003-02-06, 11:41 UTC
Location: Germany

Post by *sqa_wizard »

I could add a sample like [%temp%] to the + button list.
Function is getting better and better .. I like it
Support++
#5767 Personal license
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

OK, [%variable%] added to multi-rename tool, F7 and Shift+F4. Also supports pseudo environment variables in the form [%$variable%], and text range from a variable like [%variable%1-5].
Author of Total Commander
https://www.ghisler.com
Post Reply