update github actions
This commit is contained in:
14
.github/workflows/release.yaml
vendored
14
.github/workflows/release.yaml
vendored
@@ -6,7 +6,7 @@ permissions:
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*' # 例如 v1.0.0
|
||||
- 'v*'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
@@ -47,7 +47,7 @@ jobs:
|
||||
EXT=
|
||||
fi
|
||||
|
||||
# 打包
|
||||
# 用 PyInstaller 打包
|
||||
pyinstaller --onefile rsync-tui.py
|
||||
|
||||
# 获取 tag 名
|
||||
@@ -56,30 +56,30 @@ jobs:
|
||||
# 重命名可执行文件
|
||||
mv dist/rsync-tui${EXT} dist/rsync-tui-${SYSNAME}-${TAG_NAME}${EXT}
|
||||
|
||||
# 显示 dist 内容
|
||||
ls -l dist
|
||||
|
||||
- name: Upload build artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: rsync-tui
|
||||
name: rsync-tui-${{ runner.os }}
|
||||
path: dist/rsync-tui-*
|
||||
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
needs: build
|
||||
steps:
|
||||
- name: Download artifacts
|
||||
- name: Download all artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: rsync-tui
|
||||
path: dist
|
||||
|
||||
- name: Prepare files for release
|
||||
shell: bash
|
||||
run: |
|
||||
mkdir -p dist-root
|
||||
cp dist/* dist-root/
|
||||
for d in dist/*; do
|
||||
cp "$d"/* dist-root/
|
||||
done
|
||||
ls -l dist-root
|
||||
|
||||
- name: Create Release
|
||||
|
||||
Reference in New Issue
Block a user