sys.temp doesn't follow system env variable
I just noticed that, while cmd=user.temp properly opens the location specified in the user environment variables, cmd=sys.temp leads to the same location and ignores the system env variables.
user.temp and sys.temp do not get the result from environment variables (the results come from windows: https://learn.microsoft.com/en-us/windows/win32/shell/knownfolderid)
and yes, they point to the same folder (it is the same for user.appdata and sys.appdata)
user.tempandsys.tempdo not get the result from environment variables (the results come from windows: https://learn.microsoft.com/en-us/windows/win32/shell/knownfolderid)
Windows Environment Variables - I'm not talking about anything within Shell. So that link is kinda useless; afaik env vars don't have a static CSIDs. And 'user.temp' does what it's supposed to do, according to the env var I've set ... in Windows ... it points to my ram disk.
and yes, they point to the same folder (it is the same for
user.appdataandsys.appdata)
Then my question is 'why?'. ('Sys.temp' is a thing, unlike the strange example you chose. There's 'user.appdata' and 'user.localappdata'. I'm surprised 'sys.appdata' even resolves.)
why? - I don't know, but if I had to guess it's a "historical result": function created once in one version are not removed in subsequent version to avoid a syntax conflict if users already use that function - it was created first with sys.*. it is then created for the user.*. And another time something like this happened