Commit 4fae365f authored by Jeff Stamerjohn's avatar Jeff Stamerjohn

Merge pull request #1 from jstamerj/jstamerj/windows

Jstamerj/windows
parents b3f8a22c 32eaa39a
......@@ -50,6 +50,9 @@ func (d *VBox42Driver) IsRunning(name string) (bool, error) {
}
for _, line := range strings.Split(stdout.String(), "\n") {
// Need to trim off CR character when running in windows
line = strings.TrimRight(line, "\r");
if line == `VMState="running"` {
return true, nil
}
......
......@@ -130,6 +130,11 @@ func (c *comm) Upload(path string, input io.Reader) error {
target_dir := filepath.Dir(path)
target_file := filepath.Base(path)
// On windows, filepath.Dir uses backslash seperators (ie. "\tmp").
// This does not work when the target host is unix. Switch to forward slash
// which works for unix and windows
target_dir = filepath.ToSlash(target_dir)
// Start the sink mode on the other side
// TODO(mitchellh): There are probably issues with shell escaping the path
log.Println("Starting remote scp process in sink mode")
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment