private static List <KeyValuePair <string, string> > FindAviableMsBuildsInProgramFiles() { var programFiles = Helper.ProgramFiles(); if (programFiles == null) { return(new List <KeyValuePair <string, string> >()); } var folders = new List <string> { programFiles }; var variables = VsDevHelper.GetCurrentSetVariables(); if (variables.ContainsKey("VSINSTALLDIR")) { folders.Add(variables["VSINSTALLDIR"]); } folders.AddRange(Helper.VisualStudioVersions().Select( version => Path.Combine(programFiles, "Microsoft Visual Studio", "2017", version))); return(folders.SelectMany(FindAviableMsBuildsIn).Distinct().OrderByDescending(k => k.Key).ToList()); }
public void Init() { if (!Platform.IsUnix()) { VsDevHelper.ReplaceVariablesToVs(); ModuleBuilderHelper.FindMsBuildsWindows(); ModuleBuilderHelper.KillMsBuild(log); } }
public ModuleBuilder(ILog log, BuildSettings buildSettings) { this.log = log; this.buildSettings = buildSettings; VsDevHelper.ReplaceVariablesToVs(); }
public void Init() { VsDevHelper.ReplaceVariablesToVs(); }