Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

Require go v1.5 for compilation

Klaus Post7f2e9d9a6b3f
diff --git a/.travis.yml b/.travis.yml
index d2bf99a14..fc3836fdc 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -7,16 +7,15 @@ os:
# - osx
go:
- - 1.4.2
- 1.5.3
- 1.6
- tip
install:
- go get -t ./...
- - '[[ `go version` =~ go1.[0-4][^0-9] ]] || go get -u github.com/kisielk/errcheck'
+ - go get -u github.com/kisielk/errcheck
- go get -u golang.org/x/tools/cmd/goimports
- - '[[ `go version` =~ go1.[0-4][^0-9] ]] || go get -u github.com/golang/lint/golint'
+ - go get -u github.com/golang/lint/golint
script:
- make check
diff --git a/Makefile b/Makefile
index 7c946e27b..402ce0257 100644
--- a/Makefile
+++ b/Makefile
@@ -13,9 +13,9 @@ test: rclone
check: rclone
go vet ./...
- [[ `go version` =~ go1.[0-4][^0-9] ]] || errcheck ./...
+ errcheck ./...
goimports -d . | grep . ; test $$? -eq 1
- [[ `go version` =~ go1.[0-4][^0-9] ]] || { golint ./... | grep -E -v '(StorageUrl|CdnUrl)' ; test $$? -eq 1;}
+ golint ./... | grep -E -v '(StorageUrl|CdnUrl)' ; test $$? -eq 1
doc: rclone.1 MANUAL.html MANUAL.txt
diff --git a/docs/content/install.md b/docs/content/install.md
index 9a3b02994..d4438be05 100644
--- a/docs/content/install.md
+++ b/docs/content/install.md
@@ -1,8 +1,8 @@
---
title: "Install"
description: "Rclone Installation"
-date: "2015-06-12"
----
+date: "2016-03-28"
+------------------
Install
-------
@@ -11,15 +11,15 @@ Rclone is a Go program and comes as a single binary file.
[Download](/downloads/) the relevant binary.
-Or alternatively if you have Go installed use
+Or alternatively if you have Go 1.5+ installed use
go get github.com/ncw/rclone
and this will build the binary in `$GOPATH/bin`. If you have built
rclone before then you will want to update its dependencies first with
-this (remove `-f` if using go < 1.4)
+this
- go get -u -v -f github.com/ncw/rclone/...
+ go get -u -v github.com/ncw/rclone/...
See the [Usage section](/docs/) of the docs for how to use rclone, or
run `rclone -h`.
diff --git a/versioncheck.go b/versioncheck.go
new file mode 100644
index 000000000..fb4a4284f
--- /dev/null
+++ b/versioncheck.go
@@ -0,0 +1,6 @@
+//+build !go1.5
+
+package main
+
+// Upgrade to Go version 1.5 to compile rclone.
+func init() { Go_version_1_5_required_for_compilation() }