mirror of
https://github.com/rclone/rclone.git
synced 2024-11-07 09:04:52 +01:00
cross-compile: make rclone-beta-latest* for download #1047
This commit is contained in:
parent
5e93fe96d3
commit
1ae604fcf4
6
Makefile
6
Makefile
@ -98,17 +98,15 @@ upload_github:
|
||||
./bin/upload-github $(TAG)
|
||||
|
||||
cross: doc
|
||||
go run bin/cross-compile.go $(TAG)
|
||||
go run bin/cross-compile.go -release current $(TAG)
|
||||
|
||||
beta:
|
||||
go run bin/cross-compile.go $(TAG)β
|
||||
rm build/*-current-*
|
||||
rclone -v copy build/ memstore:pub-rclone-org/$(TAG)β
|
||||
@echo Beta release ready at http://pub.rclone.org/$(TAG)%CE%B2/
|
||||
|
||||
travis_beta:
|
||||
go run bin/cross-compile.go $(TAG)β
|
||||
rm build/*-current-*
|
||||
go run bin/cross-compile.go -release latest-beta $(TAG)β
|
||||
rclone --config bin/travis.rclone.conf -v copy build/ memstore:beta-rclone-org/$(TAG)
|
||||
@echo Beta release ready at $(BETA_URL)
|
||||
|
||||
|
@ -20,6 +20,7 @@ var (
|
||||
// Flags
|
||||
debug = flag.Bool("d", false, "Print commands instead of running them.")
|
||||
parallel = flag.Int("parallel", runtime.NumCPU(), "Number of commands to run in parallel.")
|
||||
copyAs = flag.String("release", "", "Make copies of the releases with this name")
|
||||
)
|
||||
|
||||
// GOOS/GOARCH pairs we build for
|
||||
@ -99,8 +100,10 @@ func compileArch(version, goos, goarch, dir string) {
|
||||
run("cp", "-a", "../rclone.1", dir)
|
||||
zip := dir + ".zip"
|
||||
run("zip", "-r9", zip, dir)
|
||||
currentZip := strings.Replace(zip, "-"+version, "-current", 1)
|
||||
run("ln", zip, currentZip)
|
||||
if *copyAs != "" {
|
||||
copyAsZip := strings.Replace(zip, "-"+version, "-"+*copyAs, 1)
|
||||
run("ln", zip, copyAsZip)
|
||||
}
|
||||
run("rm", "-rf", dir)
|
||||
log.Printf("Done compiling %s/%s", goos, goarch)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user