File tree Expand file tree Collapse file tree 4 files changed +283
-539
lines changed
Expand file tree Collapse file tree 4 files changed +283
-539
lines changed Original file line number Diff line number Diff line change 11name : Build
22
33on :
4+ push :
5+ branches : [ "**" ]
46 pull_request :
7+ branches : [ "**" ]
8+ workflow_dispatch :
59
610jobs :
7-
811 build :
912 runs-on : ubuntu-latest
1013 steps :
1417 - name : Install Go
1518 uses : actions/setup-go@v5
1619 with :
17- go-version : 1.22.4
20+ go-version : 1.24.1
1821
1922 - name : Prepare Env
2023 run : bash scripts/prepare_environ.sh
Original file line number Diff line number Diff line change @@ -10,21 +10,20 @@ err() {
1010
1111echo -e " \nTesting commit: ------${ANSI_GREEN} " $( git log -1 --no-merges | head -$(( $(git log - 1 -- no- merges | wc - l) - 2 )) | tail -1) " ${ANSI_RESET} ------\n"
1212
13- go get -u golang.org/x/tools/cmd/goimports
14- go get -u google.golang.org/protobuf/cmd/protoc-gen-go
15-
13+ go install golang.org/x/tools/cmd/goimports@latest
14+ go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
1615
1716BUILDDIR=.build
1817if [ ! -d " $BUILDDIR " ]; then
1918 mkdir $BUILDDIR
2019fi
2120cd $BUILDDIR
2221
23- PROTOC_ZIP=protoc-3.8.0 -linux-x86_64.zip
22+ PROTOC_ZIP=protoc-30.1 -linux-x86_64.zip
2423if [ ! -f " $PROTOC_ZIP " ]; then
2524 echo " $PROTOC_ZIP does not exist"
26- wget https://github.com/protocolbuffers/protobuf/releases/download/v3.12.3 /protoc-3.12.3 -linux-x86_64.zip
27- unzip protoc-3.12.3 -linux-x86_64.zip
25+ wget https://github.com/protocolbuffers/protobuf/releases/download/v30.1 /protoc-30.1 -linux-x86_64.zip
26+ unzip protoc-30.1 -linux-x86_64.zip
2827fi
2928
3029export PATH=$PATH :$BUILDDIR /bin/
5251fi
5352
5453make protos
55- # git status | grep "pb.go" | grep -q "modified"
56- # if [ $? -eq 0 ];then
57- # git status
58- # err "protobuf not up to date"
59- # git diff
60- # exit 1
61- # fi
54+ git status | grep " pb.go" | grep -q " modified"
55+ if [ $? -eq 0 ]; then
56+ git status
57+ err " protobuf not up to date"
58+ git diff
59+ exit 1
60+ fi
6261
6362( sleep 600; ps -ef | grep test | grep -v " go test" | grep -v grep | awk ' {print $2}' | xargs kill -SIGABRT ) &
6463
You can’t perform that action at this time.
0 commit comments