Ejemplo n.º 1
0
 public function validate()
 {
     Validate::checkExecutable($this->getSsh(), '\\Gasp\\Exception\\Ssh\\Exception');
     if (!$this->getUsername()) {
         throw new Exception('You must define the SSH username.');
     }
     if (!$this->getHost()) {
         throw new Exception('You must define the SSH hostname.');
     }
     if (!$this->getPort()) {
         throw new Exception('You must define the SSH port.');
     }
 }
Ejemplo n.º 2
0
 public function validate()
 {
     $this->classMap->validate();
     Validate::checkExecutable($this->rsync, '\\Gasp\\Extension\\Ssh\\Exception');
 }
Ejemplo n.º 3
0
 /**
  * Ensure the PHP command is available and that at least one path is defined.
  *
  * @throws Exception
  */
 public function validate()
 {
     Validate::checkExecutable($this->php, '\\Gasp\\Exception');
     if (!count($this->paths)) {
         throw new Exception('Cannot run lint task without any paths defined.');
     }
 }