Skip to content

Commit

Permalink
Fix: fix sync gitee failed & solve warning problems in action. (#142)
Browse files Browse the repository at this point in the history
* fix: fix sync gitee failed.

* build(dev): update dep version in action.

* fix: remove unnecessary indent.

* remove unnecessary space.
  • Loading branch information
mo3et authored Apr 22, 2024
1 parent eae2b4e commit a399aca
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 22 deletions.
28 changes: 14 additions & 14 deletions .github/workflows/gitee-sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@ jobs:
name: Run
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v1
- name: Mirror Github to Gitee
uses: Yikun/hub-mirror-action@v1.2
with:
src: github/go-kratos
dst: gitee/go-kratos
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }}
dst_token: ${{ secrets.GITEE_TOKEN }}
account_type: org
timeout: 600
debug: true
force_update: true
static_list: "kratos-layout"
- name: Checkout source code
uses: actions/checkout@v4
- name: Mirror Github to Gitee
uses: Yikun/hub-mirror-action@v1.3
with:
src: github/go-kratos
dst: gitee/go-kratos
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }}
dst_token: ${{ secrets.GITEE_TOKEN }}
account_type: org
timeout: 600
debug: true
force_update: true
static_list: "kratos-layout"
29 changes: 21 additions & 8 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,37 @@ name: Go

on:
push:
branches: [ main ]
branches: [main]
pull_request:
branches: [ main ]
branches: [main]

jobs:

build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v4

- name: Set up Go 1.x
uses: actions/setup-go@v2
uses: actions/setup-go@v5.0.0
with:
go-version: ^1.13
go-version: ^1.19

- name: Check out code into the Go module directory
uses: actions/checkout@v2
- name: Setup Environment
run: |
echo "GOPATH=$(go env GOPATH)" >> $GITHUB_ENV
echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
- name: Module cache
uses: actions/cache@v4
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go
- name: Get dependencies
run: |
Expand All @@ -33,4 +46,4 @@ jobs:
run: go build -v ./...

- name: Test
run: go test -v ./...
run: go test -v ./...

0 comments on commit a399aca

Please sign in to comment.