mv GO_VERSION GO_VERSION_MIN

This commit is contained in:
Ian Davis 2022-10-18 16:19:49 +01:00
parent 296eaff73c
commit e88a7f7088
3 changed files with 12 additions and 12 deletions

View File

@ -5,7 +5,7 @@ orbs:
executors:
golang:
docker:
# Must match GO_VERSION in project root
# Must match GO_VERSION_MIN in project root
- image: cimg/go:1.18.1
resource_class: 2xlarge
ubuntu:
@ -49,9 +49,9 @@ commands:
name: Check Go Version
command: |
v=`go version | { read _ _ v _; echo ${v#go}; }`
if [[ $v != `cat GO_VERSION` ]]; then
echo "GO_VERSION file does not match the go version being used."
echo "Please update image to cimg/go:`cat GO_VERSION` or update GO_VERSION to $v."
if [[ $v != `cat GO_VERSION_MIN` ]]; then
echo "GO_VERSION_MIN file does not match the go version being used."
echo "Please update image to cimg/go:`cat GO_VERSION_MIN` or update GO_VERSION_MIN to $v."
exit 1
fi
- run: sudo apt-get update
@ -62,7 +62,7 @@ commands:
- run:
name: Install Go
command: |
curl https://dl.google.com/go/go`cat GO_VERSION`.darwin-amd64.pkg -o /tmp/go.pkg && \
curl https://dl.google.com/go/go`cat GO_VERSION_MIN`.darwin-amd64.pkg -o /tmp/go.pkg && \
sudo installer -pkg /tmp/go.pkg -target /
- run:
name: Export Go
@ -438,7 +438,7 @@ jobs:
name: Update Go
command: |
sudo rm -rf /usr/local/go && \
curl -L https://golang.org/dl/go`cat GO_VERSION`.linux-amd64.tar.gz -o /tmp/go.tar.gz && \
curl -L https://golang.org/dl/go`cat GO_VERSION_MIN`.linux-amd64.tar.gz -o /tmp/go.tar.gz && \
sudo tar -C /usr/local -xvf /tmp/go.tar.gz
- run: go version
- run:

View File

@ -5,7 +5,7 @@ orbs:
executors:
golang:
docker:
# Must match GO_VERSION in project root
# Must match GO_VERSION_MIN in project root
- image: cimg/go:1.18.1
resource_class: 2xlarge
ubuntu:
@ -49,9 +49,9 @@ commands:
name: Check Go Version
command: |
v=`go version | { read _ _ v _; echo ${v#go}; }`
if [["[[ $v != `cat GO_VERSION` ]]"]]; then
echo "GO_VERSION file does not match the go version being used."
echo "Please update image to cimg/go:`cat GO_VERSION` or update GO_VERSION to $v."
if [["[[ $v != `cat GO_VERSION_MIN` ]]"]]; then
echo "GO_VERSION_MIN file does not match the go version being used."
echo "Please update image to cimg/go:`cat GO_VERSION_MIN` or update GO_VERSION_MIN to $v."
exit 1
fi
- run: sudo apt-get update
@ -62,7 +62,7 @@ commands:
- run:
name: Install Go
command: |
curl https://dl.google.com/go/go`cat GO_VERSION`.darwin-amd64.pkg -o /tmp/go.pkg && \
curl https://dl.google.com/go/go`cat GO_VERSION_MIN`.darwin-amd64.pkg -o /tmp/go.pkg && \
sudo installer -pkg /tmp/go.pkg -target /
- run:
name: Export Go
@ -438,7 +438,7 @@ jobs:
name: Update Go
command: |
sudo rm -rf /usr/local/go && \
curl -L https://golang.org/dl/go`cat GO_VERSION`.linux-amd64.tar.gz -o /tmp/go.tar.gz && \
curl -L https://golang.org/dl/go`cat GO_VERSION_MIN`.linux-amd64.tar.gz -o /tmp/go.tar.gz && \
sudo tar -C /usr/local -xvf /tmp/go.tar.gz
- run: go version
- run: