Skip to content

Commit aeef64a

Browse files
authored
Workflow for build
1 parent 352b48c commit aeef64a

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

.github/workflows/build.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: build
2+
on:
3+
push:
4+
branches: [ "master" ]
5+
# pull_request:
6+
# branches: [ "master" ]
7+
workflow_dispatch:
8+
9+
jobs:
10+
run_build:
11+
runs-on: ubuntu-latest
12+
steps:
13+
14+
- name: clone repo
15+
uses: actions/checkout@v3
16+
17+
- name: download and install
18+
uses: actions/setup-go@v5
19+
with:
20+
go-version: '${{ vars.VERSION }}'
21+
22+
- name: protobuff install
23+
run: |
24+
sudo apt update
25+
sudo apt install protobuf-compiler
26+
27+
- name: go_ins_1
28+
run: go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
29+
30+
- name: go_ins_2
31+
run: go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
32+
33+
- name: generate
34+
run: go generate ./...
35+
36+
- name: check version
37+
run: go version
38+
39+
- name: check folder
40+
run: ls
41+
42+
- name: do build
43+
run: go build snetd/main.go

0 commit comments

Comments
 (0)