예제 #1
0
        static void Main(string[] args)
        {
            try
            {
                var parameters = GetParameters(args);
                var core = new Core(parameters);

                var extrasFolderCatalog = new DirectoryCatalog(@".\extras\");
                var currentAssemblyCatalog = new AssemblyCatalog(typeof(Program).Assembly);
                var aggregateCatalog = new AggregateCatalog(extrasFolderCatalog, currentAssemblyCatalog);

                var container = new CompositionContainer(aggregateCatalog);
                container.ComposeParts(core);

                core.Run();

                Console.WriteLine("Static site created successfully");

                if (Debugger.IsAttached)
                    Console.ReadLine();
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.ToString());

                if (Debugger.IsAttached)
                    Console.ReadLine();

                Environment.ExitCode = 1;
            }
        }
예제 #2
0
파일: Program.cs 프로젝트: uuuumar/graze
        static void Main(string[] args)
        {
            try
            {
                var parameters = GetParameters(args);
                var core       = new Core(parameters);

                var extrasFolderCatalog    = new DirectoryCatalog(@".\extras\");
                var currentAssemblyCatalog = new AssemblyCatalog(typeof(Program).Assembly);
                var aggregateCatalog       = new AggregateCatalog(extrasFolderCatalog, currentAssemblyCatalog);

                var container = new CompositionContainer(aggregateCatalog);
                container.ComposeParts(core);

                core.Run();

                Console.WriteLine("Static site created successfully");

                if (Debugger.IsAttached)
                {
                    Console.ReadLine();
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.ToString());

                if (Debugger.IsAttached)
                {
                    Console.ReadLine();
                }

                Environment.ExitCode = 1;
            }
        }
예제 #3
0
파일: Program.cs 프로젝트: yevhen/graze
        static void Main(string[] args)
        {
            try
            {
                var parameters = GetParameters(args);
                var core       = new Core(parameters);

                core.Run();

                Console.WriteLine("Static site created successfully");
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.ToString());

                if (Debugger.IsAttached)
                {
                    Console.ReadLine();
                }

                Environment.ExitCode = 1;
            }
        }