Skip to content

Commit

Permalink
Create build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
SugarMGP committed Dec 5, 2024
1 parent 53235cd commit 4f4c213
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Build

on:
push:
pull_request:
branches:
- dev

jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.22 # 指定 Go 的版本

- name: Install GCC
run: |
sudo apt-get update
sudo apt-get install -y build-essential
- name: Build
run: go build -o build .

- name: Archive Output
run: |
mkdir -p artifacts
zip -j artifacts/build-output.zip build
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: build-output
path: artifacts/build-output.zip

0 comments on commit 4f4c213

Please sign in to comment.