File tree 2 files changed +2
-1
lines changed
Cli/Microsoft.TemplateEngine.Cli/Commands
RazorSdk/Tool/ServerProtocol
2 files changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -42,6 +42,7 @@ private static string GetUserProfileDir(IEnvironment environment) => environment
42
42
RuntimeInformation . IsOSPlatform ( OSPlatform . Windows )
43
43
? "USERPROFILE"
44
44
: "HOME" )
45
+ ?? Environment . GetFolderPath ( Environment . SpecialFolder . UserProfile )
45
46
?? throw new NotSupportedException ( "HOME or USERPROFILE environment variable is not defined, the environment is not supported" ) ;
46
47
47
48
private static string GetGlobalSettingsDir ( string ? settingsLocation )
Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ public static string GetTempPath(string workingDir)
77
77
}
78
78
}
79
79
80
- var userProfile = Environment . GetEnvironmentVariable ( "USERPROFILE" ) ;
80
+ var userProfile = Environment . GetFolderPath ( Environment . SpecialFolder . UserProfile ) ;
81
81
if ( Path . IsPathRooted ( userProfile ) )
82
82
{
83
83
return userProfile ;
You can’t perform that action at this time.
0 commit comments