Merge pull request #263 from Code0x58/ssh-external-tidy

Stop quietly ignoring `--ssh-external` on Windows
This commit is contained in:
Kota Kanbe
2016-11-16 16:31:58 +09:00
committed by GitHub
3 changed files with 12 additions and 8 deletions

View File

@@ -19,6 +19,7 @@ package config
import (
"fmt"
"runtime"
"strings"
log "github.com/Sirupsen/logrus"
@@ -71,6 +72,10 @@ type Config struct {
func (c Config) Validate() bool {
errs := []error{}
if runtime.GOOS == "windows" && c.SSHExternal {
errs = append(errs, fmt.Errorf("-ssh-external cannot be used on windows"))
}
if len(c.ResultsDir) != 0 {
if ok, _ := valid.IsFilePath(c.ResultsDir); !ok {
errs = append(errs, fmt.Errorf(