public static Mysql Initialize() { var mysqlDriver = new ProcessDriver(Global.MysqlFile, "mysqld.exe", "--defaults-file=\"" + Global.Mysql + "/my.ini\" --console --initialize-insecure --user=root"); mysqlDriver.OutputTrigger += (ot, dt) => Console.WriteLine(@"{0} {1}", ot, dt); mysqlDriver.Start(); mysqlDriver.WaitForExit(); return new Mysql(); }
public Apache() { apacheDriver = new ProcessDriver(Global.ApacheFile, "httpd.exe", "-f \"" + Global.Apache + "/conf/httpd.conf\""); apacheDriver.OutputTrigger += (ot, dt) => Console.WriteLine(@"{0} {1}", ot, dt); fileWatcher = new FileWatcher(Global.SettingsRoot, "apache_*.cc"); fileWatcher.FileChanged += path => { Global.Compiler.Compile(path); Restart();}; }
public Mysql() { mysqlDriver = new ProcessDriver(Global.MysqlFile, "mysqld.exe", "--defaults-file=\"" + Global.Mysql + "/my.ini\" --console"); mysqlDriver.OutputTrigger += (ot, dt) => Console.WriteLine(@"{0} {1}", ot, dt); fileWatcher = new FileWatcher(Global.SettingsRoot, "mysql_*.cc"); fileWatcher.FileChanged += path => { Global.Compiler.Compile(path); Restart();}; }