File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -87,12 +87,19 @@ private static void CreateAndApplyRestrictedACL(string path)
8787 /// <returns>full app data with with optional subdirectory</returns>
8888 public static string CreateAppDataPath ( string subDirectory = null , bool skipCreation = false )
8989 {
90+ // use the environment variable CERTIFY_APPDATA_PATH if set, otherwise use the common app data folder
9091 var parts = new List < string > ( )
9192 {
9293 Environment . GetFolderPath ( Environment . SpecialFolder . CommonApplicationData ) ,
9394 Models . SharedConstants . APPDATASUBFOLDER
9495 } ;
9596
97+ if ( ! string . IsNullOrEmpty ( Environment . GetEnvironmentVariable ( "CERTIFY_APPDATA_PATH" ) ) )
98+ {
99+ parts = new List < string > { Environment . GetEnvironmentVariable ( "CERTIFY_APPDATA_PATH" ) } ;
100+ }
101+
102+ // if per instance settings are enabled, include the machine name in the path
96103 if ( Environment . GetEnvironmentVariable ( "CERTIFY_ENABLE_PER_INSTANCE_SETTINGS" ) ? . ToLowerInvariant ( ) == "true" )
97104 {
98105 parts . Add ( Environment . MachineName . ToLowerInvariant ( ) . Trim ( ) ) ;
You can’t perform that action at this time.
0 commit comments