Browse Source

Windows: reexec pkg supported

Signed-off-by: John Howard <jhoward@microsoft.com>
John Howard 10 years ago
parent
commit
64715c4f33
2 changed files with 15 additions and 1 deletions
  1. 1 1
      pkg/reexec/command_unsupported.go
  2. 14 0
      pkg/reexec/command_windows.go

+ 1 - 1
pkg/reexec/command_unsupported.go

@@ -1,4 +1,4 @@
-// +build !linux
+// +build !linux,!windows
 
 
 package reexec
 package reexec
 
 

+ 14 - 0
pkg/reexec/command_windows.go

@@ -0,0 +1,14 @@
+// +build windows
+
+package reexec
+
+import (
+	"os/exec"
+)
+
+func Command(args ...string) *exec.Cmd {
+	return &exec.Cmd{
+		Path: Self(),
+		Args: args,
+	}
+}