Skip to content

upgrade v12 to go 1.20@latest #438

upgrade v12 to go 1.20@latest

upgrade v12 to go 1.20@latest #438

Workflow file for this run

name: check_imports
on: [pull_request,push]
jobs:
build:
name: Check Imports
runs-on:
group: vitess-ubuntu20
steps:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.21'
check-latest: true
- name: Check out code
uses: actions/checkout@v2
- name: Install goimports
run: |
go install golang.org/x/tools/cmd/goimports@latest
- name: Run goimports
run: |
out=$(goimports -local vitess.io/vitess -l -w $(find . -name "*.go" | grep -v ".pb.go"))
echo $out | grep go > /dev/null && echo -e "The following files are malformatted:\n$out" && exit 1 || echo "All the files are formatted correctly"