Require go v1.5 for compilation

Google cloud package requires go v1.5 to compile, so we need to require the same for rclone.

Fixes #408
This commit is contained in:
Klaus Post 2016-03-28 12:36:52 +02:00 committed by Nick Craig-Wood
parent 6cc9c09610
commit 7f2e9d9a6b
4 changed files with 15 additions and 10 deletions

View File

@ -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

View File

@ -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

View File

@ -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`.

6
versioncheck.go Normal file
View File

@ -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() }