cm_CreateShortcut command not working with variables

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

Moderators: white, Hacker, petermad, Stefan2

Post Reply
User avatar
rus73
Junior Member
Junior Member
Posts: 29
Joined: 2013-05-30, 08:39 UTC
Location: Russia

cm_CreateShortcut command not working with variables

Post by *rus73 »

Why cm_Create Shortcut command doesn't work with variables?

Code: Select all

cm_CreateShortcut /GT="%$DESKTOP%"
cm_CreateShortcut /GT="%USERPROFILE%\Desktop"
Do not Working.
User avatar
Sir_SiLvA
Power Member
Power Member
Posts: 3278
Joined: 2003-05-06, 11:46 UTC

Re: cm_CreateShortcut command not working with variables

Post by *Sir_SiLvA »

rus73 wrote: 2023-05-22, 00:32 UTC Why cm_Create Shortcut command doesn't work with variables?
Sorry, but WHERE is this a BUG?
rus73 wrote: 2023-05-22, 00:32 UTC

Code: Select all

cm_CreateShortcut /GT="%$DESKTOP%"
cm_CreateShortcut /GT="%USERPROFILE%\Desktop"
Do not Working.
Because it is not implemented.
Hoecker sie sind raus!
Fla$her
Power Member
Power Member
Posts: 2247
Joined: 2020-01-18, 04:03 UTC

Re: cm_CreateShortcut command not working with variables

Post by *Fla$her »

This is a bug for the "Command:" field. First, the environment variables should be disclosed, and only then the parameters of the internal command should be considered.
For example, for TCFS2.exe /ef "tem(`cm_CreateShortcut /T=%$DESKTOP%`)" there is no such problem, because this principle applies here.
Overquoting is evil! 👎
User avatar
rus73
Junior Member
Junior Member
Posts: 29
Joined: 2013-05-30, 08:39 UTC
Location: Russia

Re: cm_CreateShortcut command not working with variables

Post by *rus73 »

Fla$her
Yes i use this command %COMMANDER_PATH%\Utility\TCFS2\TCFS2.exe /ef "tem(`cm_CreateShortcut /GT="%$DESKTOP%"`)".
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: cm_CreateShortcut command not working with variables

Post by *ghisler(Author) »

The /T parameter in cm_CreateShortcut, cm_copy and cm_renmov doesn't currently support environment variables. I will add it.
Author of Total Commander
https://www.ghisler.com
User avatar
rus73
Junior Member
Junior Member
Posts: 29
Joined: 2013-05-30, 08:39 UTC
Location: Russia

Re: cm_CreateShortcut command not working with variables

Post by *rus73 »

Great, and we'll be waiting for it.
Thank you very much!
Fla$her
Power Member
Power Member
Posts: 2247
Joined: 2020-01-18, 04:03 UTC

Re: cm_CreateShortcut command not working with variables

Post by *Fla$her »

Fixed in 11.00b4.
Overquoting is evil! 👎
Post Reply