Skip to content

发行

发行 #6

Workflow file for this run

name: 发行
on:
workflow_dispatch:
inputs:
rname:
description: '发行版名称'
type: string
tag_name:
description: '标签名称'
type: string
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: windows-latest
steps:
- name: 仓库初始化
uses: actions/checkout@v3
- name: 安装 Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: Rust 缓存
uses: Swatinem/rust-cache@v2.7.3
- name: 编译exe
uses: actions-rs/cargo@v1
with:
command: build
args: --release
#- name: 上传文件
# uses: actions/upload-artifact@v4
# with:
# name: AppDataCleaner
# path: |
# target\release\AppDataCleaner.exe
# target\release\AppDataCleaner.pdb
- name: 自动发布发行版
uses: softprops/action-gh-release@v2
with:
name: ${{ inputs.rname }}
tag_name: ${{ inputs.tag_name }}
draft: false
make_latest: true
files: |
target/release/AppDataCleaner.exe
target/release/AppDataCleaner.pdb
env:
GITHUB_TOKEN: ${{ secrets.MY_GITHUB_TOKEN }}