Example #1
0
        static void Main()
        {
            CrowIDE win = new CrowIDE();

            MainWin = win;
            win.Run(30);
        }
Example #2
0
        /// <summary>
        /// Creates new solution.
        /// </summary>
        public SolutionView(CrowIDE ide, string path)
        {
            this.IDE     = ide;
            this.path    = path;
            solutionFile = SolutionFile.Parse(path);
            UserConfig   = new Configuration(path + ".user");

            ActiveConfiguration = solutionFile.GetDefaultConfigurationName();
            ActivePlatform      = solutionFile.GetDefaultPlatformName();

            ide.projectCollection.SetGlobalProperty("SolutionDir", Path.GetDirectoryName(path) + "/");
            //ide.projectCollection.HostServices
            buildParams = new BuildParameters(ide.projectCollection)
            {
                Loggers     = ide.projectCollection.Loggers,
                ResetCaches = true,
                LogInitialPropertiesAndItems = true
            };
            //projectCollection.IsBuildEnabled = false;

            BuildManager.DefaultBuildManager.ResetCaches();

#if NET472
            ide.projectCollection.SetGlobalProperty("RoslynTargetsPath", Path.Combine(Startup.msbuildRoot, "Roslyn/"));
            ide.projectCollection.SetGlobalProperty("MSBuildSDKsPath", Path.Combine(Startup.msbuildRoot, "Sdks/"));
#endif
            //------------

            foreach (ProjectInSolution pis in solutionFile.ProjectsInOrder)
            {
                switch (pis.ProjectType)
                {
                case SolutionProjectType.Unknown:
                    break;

                case SolutionProjectType.KnownToBeMSBuildFormat:
                    Projects.Add(new ProjectView(this, pis));
                    break;

                case SolutionProjectType.SolutionFolder:
                    break;

                case SolutionProjectType.WebProject:
                    break;

                case SolutionProjectType.WebDeploymentProject:
                    break;

                case SolutionProjectType.EtpSubProject:
                    break;

                case SolutionProjectType.SharedProject:
                    break;
                }
            }

            ReloadStyling();
            ReloadDefaultTemplates();
        }
Example #3
0
        static void start()
        {
#if NET472
            var nativeSharedMethod = typeof(Microsoft.Build.Construction.SolutionFile).Assembly.GetType("Microsoft.Build.Shared.NativeMethodsShared");
            var isMonoField        = nativeSharedMethod.GetField("_isMono", BindingFlags.Static | BindingFlags.NonPublic);
            isMonoField.SetValue(null, true);

            Environment.SetEnvironmentVariable("MSBUILD_EXE_PATH", Path.Combine(msbuildRoot, "MSBuild.dll"));
#endif
            Environment.SetEnvironmentVariable("MSBUILD_NUGET_PATH", "/home/jp/.nuget/packages");
            Environment.SetEnvironmentVariable("FrameworkPathOverride", "/usr/lib/mono/4.5/");

            using (CrowIDE app = new CrowIDE()) {
                app.Run();
                app.saveWinConfigs();
            }
        }
Example #4
0
 public IdeLogger(CrowIDE ide)
 {
     this.ide = ide;
 }