mirror of
https://github.com/zu1k/nali.git
synced 2025-02-09 05:42:43 +08:00
chore: Add action for aur nali-go-git
Signed-off-by: zu1k <i@zu1k.com>
This commit is contained in:
parent
6f570491b6
commit
3f2728b02a
21
.github/workflows/go.yml
vendored
21
.github/workflows/go.yml
vendored
@ -2,18 +2,16 @@ name: Go
|
|||||||
on: [push, pull_request]
|
on: [push, pull_request]
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
build:
|
test-build:
|
||||||
name: Build
|
name: Test and Build
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v3
|
uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: '^1.18'
|
go-version: '^1.18'
|
||||||
|
|
||||||
- name: Check out code into the Go module directory
|
- name: Check out code into the Go module directory
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Cache go module
|
- name: Cache go module
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
@ -21,10 +19,21 @@ jobs:
|
|||||||
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-go-
|
${{ runner.os }}-go-
|
||||||
|
|
||||||
- name: Get dependencies and run test
|
- name: Get dependencies and run test
|
||||||
run: |
|
run: |
|
||||||
go test ./...
|
go test ./...
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: go build
|
run: go build
|
||||||
|
|
||||||
|
release-aur-git:
|
||||||
|
name: Release Aur Git
|
||||||
|
needs: [test-build]
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Publish AUR package
|
||||||
|
uses: guumaster/aur-publish-docker-action@master
|
||||||
|
with:
|
||||||
|
package_name: nali-go-git
|
||||||
|
commit_username: 'zu1k'
|
||||||
|
commit_email: 'i@zu1k.com'
|
||||||
|
ssh_private_key: ${{ secrets.AUR_SSH_PRIVATE_KEY }}
|
||||||
|
Loading…
Reference in New Issue
Block a user