Don't close the cmd promt right away on windows
This commit is contained in:
parent
85feb33730
commit
ca5dee2467
6
main.go
6
main.go
|
@ -9,6 +9,7 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"path"
|
"path"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
|
"runtime"
|
||||||
"strings"
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -80,4 +81,9 @@ func main() {
|
||||||
|
|
||||||
// 4. Done
|
// 4. Done
|
||||||
fmt.Println("Done!")
|
fmt.Println("Done!")
|
||||||
|
|
||||||
|
if runtime.GOOS == "windows" {
|
||||||
|
fmt.Println("Press enter to close this window...")
|
||||||
|
_, _ = readText()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue