In answer to @StevenPenny asking for sourced answers: There are surprisingly few such,
and almost none from Microsoft. Below are a few sources.
Upgrade to Windows versions that is before Windows 10 is blocked if Users and ProgramData directories are changed
One of the few sources by Microsoft:
%systemdrive% is defined as the drive that contains the Windows directory.
HOMEPATH
On a Microsoft Windows system, the %HOMEPATH% is the name for what
Unix/Linux users call $HOME. When combined with the %HOMEDRIVE%
environment variable you get a complete path to the user's home
directory.
For example, if your username is “JRandom” then your home drive and
path is probably one of the following:
C:\Users\JRandom (Windows 7 and newer)
C:\Documents and Settings\JRandom (XP and older)
Windows environment variables
Variable |
Possible value |
|
registry |
HOMEDRIVE |
C: |
The combination of HOMEDRIVE and HOMEPATH points to a location where personal files should be stored. It might, but needs not to, be the same directory as %USERPROFILE% |
HKCU\Volatile Environment |
HOMEPATH |
\Users\Rene |
Rene correpsonds to %USERNAME%. Compare with %USERPROFILE% |
HKCU\Volatile Environment |
PowerShell : About Automatic Variables
Another Microsoft article that mentions these variables:
$HOME
Contains the full path of the user's home directory. This variable is
the equivalent of the "$env:homedrive$env:homepath" Windows
environment variables, typically C:\Users<UserName>.
HomeDrive
is described as the drive letter assigned to the volume which contains your user profiles andSystemDrive
as the drive letter of the volume where Windows is installed. So as I understand, the values of these variables are different only if you somehow installed your User profile on the different drive than the operating system itself.