fix: 替换 setup-node/setup-go 为 shell 安装命令 (Gitea 无法访问 GitHub Actions)
Some checks failed
Release / build-and-release (push) Failing after 2m54s
Some checks failed
Release / build-and-release (push) Failing after 2m54s
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -10,11 +10,11 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Setup Node.js
|
- name: Setup Node.js
|
||||||
uses: actions/setup-node@v4
|
run: |
|
||||||
with:
|
apt-get update -qq
|
||||||
node-version: 20
|
apt-get install -y -qq nodejs npm 2>/dev/null || true
|
||||||
cache: "npm"
|
node --version
|
||||||
cache-dependency-path: frontend/package-lock.json
|
npm --version
|
||||||
|
|
||||||
- name: Build frontend
|
- name: Build frontend
|
||||||
run: |
|
run: |
|
||||||
@@ -23,10 +23,16 @@ jobs:
|
|||||||
npm run build
|
npm run build
|
||||||
|
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v5
|
run: |
|
||||||
with:
|
if ! command -v go &>/dev/null; then
|
||||||
go-version: "1.22"
|
apt-get install -y -qq golang-go 2>/dev/null || {
|
||||||
cache-dependency-path: backend/go.sum
|
wget -q https://go.dev/dl/go1.22.5.linux-amd64.tar.gz
|
||||||
|
tar -C /usr/local -xzf go1.22.5.linux-amd64.tar.gz
|
||||||
|
echo "/usr/local/go/bin" >> "$GITHUB_PATH"
|
||||||
|
export PATH="$PATH:/usr/local/go/bin"
|
||||||
|
}
|
||||||
|
fi
|
||||||
|
go version
|
||||||
|
|
||||||
- name: Build all platforms
|
- name: Build all platforms
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user