public static void Build() { var args = Environment.GetCommandLineArgs().Concat(new string[] { "" }).ToArray(); // オプションのみと そもそも入っていないの識別 var options = new string[] { "-parameter", }; var name = options.ToDictionary(p => p.Substring(1), p => args.SkipWhile(a => a != p).Skip(1).FirstOrDefault())["parameter"]; if (name == null) { BuildProcess.Build(); } else { BuildProcess.Build(name); } }
public void Build() { RegisterActiveParameter(); BuildProcess.Build(); }