public CommandLineInvocation Build() { var argLine = new List <string>(); #if NET40 #else if (dotnet && !CrossPlatform.IsWindows()) { argLine.Add(executable); if (action != null) { argLine.Add(action); } argLine.AddRange(arguments); return(new CommandLineInvocation("dotnet", string.Join(" ", argLine))); } #endif if (action != null) { argLine.Add(action); } argLine.AddRange(arguments); return(new CommandLineInvocation(executable, string.Join(" ", argLine))); }