Skip to content

Commit 46b872c

Browse files
committed
Added commandline arg config value for AppMan for custom config files...
1 parent 942c5f1 commit 46b872c

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

External/Tools/AppMan/MainForm.cs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,11 @@ public partial class MainForm : Form, IMessageFilter
3333
private Queue<String> fileQueue;
3434
private LocaleData localeData;
3535
private Boolean localeOverride;
36+
private Boolean configOverride;
3637
private String[] notifyPaths;
3738
private Boolean haveUpdates;
3839
private Boolean checkOnly;
40+
private String argsConfig;
3941

4042
/**
4143
* Static link label margin constant
@@ -129,6 +131,12 @@ private void CheckArgs(String[] args)
129131
this.localeId = arg.Trim().Substring("-locale=".Length);
130132
this.localeOverride = true;
131133
}
134+
// Handle config values
135+
if (arg.Trim().Contains("-config="))
136+
{
137+
this.argsConfig = arg.Trim().Substring("-config=".Length);
138+
this.configOverride = true;
139+
}
132140
}
133141
}
134142

@@ -238,6 +246,10 @@ private void InitializeSettings()
238246
if (!this.localeOverride) this.localeId = settings.Locale;
239247
this.notifyPaths = settings.Paths;
240248
}
249+
if (this.configOverride)
250+
{
251+
PathHelper.CONFIG_ADR = this.argsConfig;
252+
}
241253
if (!Directory.Exists(PathHelper.LOG_DIR))
242254
{
243255
Directory.CreateDirectory(PathHelper.LOG_DIR);
512 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)