Skip to content
This repository was archived by the owner on Sep 30, 2022. It is now read-only.

Commit 1f0749b

Browse files
committed
remove -release flag; include WiX by default
1 parent 403249b commit 1f0749b

File tree

2 files changed

+3
-38
lines changed

2 files changed

+3
-38
lines changed

README

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ and then on Windows do something like this:
77

88
The latest windows executable is:
99

10-
https://storage.googleapis.com/winstrap/winstrap-2015-01-03-43d7fa3.exe
10+
https://storage.googleapis.com/winstrap/winstrap-2015-02-11-046f2a8.exe

winstrap.go

+2-37
Original file line numberDiff line numberDiff line change
@@ -26,18 +26,15 @@ var files = map[string]string{
2626
// "tdm64-gcc-4.8.1-3.exe": "http://downloads.sourceforge.net/project/tdm-gcc/TDM-GCC%20Installer/tdm64-gcc-4.8.1-3.exe?r=http%3A%2F%2Ftdm-gcc.tdragon.net%2Fdownload&ts=1407729829&use_mirror=ufpr",
2727
"tdm-gcc-4.9.2.exe": "http://downloads.sourceforge.net/project/tdm-gcc/TDM-GCC%20Installer/tdm-gcc-4.9.2.exe?r=http%3A%2F%2Ftdm-gcc.tdragon.net%2Fdownload&ts=1420336642&use_mirror=hivelocity",
2828

29-
wixFilename: "http://download-codeplex.sec.s-msft.com/Download/Release?ProjectName=wix&DownloadId=204417&FileTime=129409234222130000&Build=20919",
29+
"Wix35.msi": "http://storage.googleapis.com/winstrap/Wix35.msi",
3030
"Install Git.exe": "https://github.com/msysgit/msysgit/releases/download/Git-1.9.5-preview20141217/Git-1.9.5-preview20141217.exe",
3131
"Start Buildlet.exe": "https://storage.googleapis.com/go-builder-data/buildlet-stage0.windows-amd64",
3232
}
3333

34-
const wixFilename = "Wix35.msi"
35-
3634
var altMain func()
3735

3836
var (
3937
flagYes = flag.Bool("yes", false, "Run without prompt")
40-
release = flag.Bool("release", false, "Set up a release builder")
4138
homeDir = flag.String("home", defaultHome(), "custom home directory")
4239
)
4340

@@ -56,7 +53,7 @@ func main() {
5653
}
5754
flag.Parse()
5855
if !*flagYes {
59-
log.Printf("This program will first download TDM-GCC, Wix, and Git, then let you optinally install Go and do a release.\nType 'go<enter>' to proceed.")
56+
log.Printf("This program will first download TDM-GCC, Wix, and Git, then let you optinally install Go.\nType 'go<enter>' to proceed.")
6057
waitForGo()
6158
}
6259

@@ -69,9 +66,6 @@ func main() {
6966
log.Printf("Downloading files.")
7067
var errs []chan error
7168
for file, url := range files {
72-
if !*release && file == wixFilename {
73-
continue
74-
}
7569
errc := make(chan error)
7670
errs = append(errs, errc)
7771
go func(file, url string) {
@@ -103,10 +97,6 @@ func main() {
10397
runGoMakeBat("386")
10498
runGoMakeBat("amd64")
10599

106-
if *release {
107-
buildMakerelease()
108-
}
109-
110100
log.Printf(`Installed go to %v, please add %v\bin to your PATH`, goroot(), goroot())
111101

112102
fmt.Println("[ Press enter to exit ]")
@@ -144,31 +134,6 @@ func runGoMakeBat(arch string) {
144134
log.Printf("ran make.bat for arch %s", arch)
145135
}
146136

147-
func buildMakerelease() {
148-
goCmd := filepath.Join(goroot(), "bin", "go.exe")
149-
mrDir := filepath.Join(goroot(), "misc", "makerelease")
150-
env := append(
151-
[]string{"GOPATH=" + gopath()},
152-
removeEnvs(os.Environ(), "GOPATH")...)
153-
bin := filepath.Join(home(), "makerelease.exe")
154-
155-
goDo := func(args ...string) {
156-
cmd := exec.Command(goCmd, args...)
157-
cmd.Dir = mrDir
158-
cmd.Stdout = os.Stdout
159-
cmd.Stderr = os.Stderr
160-
cmd.Env = env
161-
if err := cmd.Run(); err != nil {
162-
log.Fatal(err)
163-
}
164-
}
165-
166-
log.Print("Fetching dependencies for makerelease...")
167-
goDo("get", "-d")
168-
log.Println("Building and installing makerelease to", bin)
169-
goDo("build", "-o", bin)
170-
}
171-
172137
func removeEnvs(envs []string, removeKeys ...string) []string {
173138
var ret []string
174139
for _, env := range envs {

0 commit comments

Comments
 (0)