public function run()
 {
     // set-up required vars
     $options = array();
     $options["moveStatic"] = Console::findCommandOption("p|patternsonly") ? false : true;
     $options["noCacheBuster"] = Console::findCommandOption("n|nocache");
     // see if the starterKit flag was passed so you know what dir to watch
     if (Console::findCommandOption("sk")) {
         // load the starterkit watcher
         $w = new Watcher();
         $w->watchStarterKit();
     } else {
         if (Console::findCommandOption("no-procs")) {
             // don't have to worry about loading processes so launch watcher
             // load the generator
             $g = new Generator();
             $g->generate($options);
             // load the watcher
             $w = new Watcher();
             $w->watch($options);
         } else {
             // a vanilla --watch command needs to have a --no-procs version built
             // so we don't get caught in while() loops. re-request the console command
             $commands = array();
             $commands[] = array("command" => $this->build() . " --no-procs", "timeout" => null, "idle" => 600);
             Console::writeInfo("spawning the watch process...");
             $process = new ProcessSpawner();
             $process->spawn($commands);
         }
     }
 }
 public function run()
 {
     // set-up required vars
     $options = array();
     $options["moveStatic"] = Console::findCommandOption("p|patternsonly") ? false : true;
     $options["noCacheBuster"] = Console::findCommandOption("n|nocache");
     // DEPRECATED
     // $options["autoReload"]    = Console::findCommandOption("r|autoreload");
     // see if the starterKit flag was passed so you know what dir to watch
     if (Console::findCommandOption("sk")) {
         // load the starterkit watcher
         $w = new Watcher();
         $w->watchStarterKit();
     } else {
         // load the generator
         $g = new Generator();
         $g->generate($options);
         // load the watcher
         $w = new Watcher();
         $w->watch($options);
     }
 }