Compare commits

..

2 Commits

Author SHA1 Message Date
2241230a7a
chore: v0.0.98 2024-04-01 00:32:34 +08:00
fb4b1fb9b8
ci: build package using github actions 2024-04-01 00:26:12 +08:00
2 changed files with 51 additions and 3 deletions

View File

@ -0,0 +1,48 @@
name: "Build and draft a release"
on:
workflow_dispatch:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+"
permissions:
contents: write
discussions: write
jobs:
build-and-draft-release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python environment
uses: actions/setup-python@v5
with:
python-version: "3.x"
- name: Build package
run: |
pip install build
python -m build
- name: Remove `v` in tag name
uses: mad9000/actions-find-and-replace-string@5
id: tagNameReplaced
with:
source: ${{ github.ref_name }}
find: "v"
replace: ""
- name: Draft a release
uses: softprops/action-gh-release@v2
with:
discussion_category_name: New releases
draft: true
generate_release_notes: true
files: |
dist/arcaea_offline_ocr-${{ steps.tagNameReplaced.outputs.value }}*.whl
dist/arcaea-offline-ocr-${{ steps.tagNameReplaced.outputs.value }}.tar.gz

View File

@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
[project] [project]
name = "arcaea-offline-ocr" name = "arcaea-offline-ocr"
version = "0.0.97" version = "0.0.98"
authors = [{ name = "283375", email = "log_283375@163.com" }] authors = [{ name = "283375", email = "log_283375@163.com" }]
description = "Extract your Arcaea play result from screenshot." description = "Extract your Arcaea play result from screenshot."
readme = "README.md" readme = "README.md"
@ -16,8 +16,8 @@ classifiers = [
] ]
[project.urls] [project.urls]
"Homepage" = "https://github.com/283375/arcaea-offline-ocr" "Homepage" = "https://github.com/ArcaeaOffline/core-ocr"
"Bug Tracker" = "https://github.com/283375/arcaea-offline-ocr/issues" "Bug Tracker" = "https://github.com/ArcaeaOffline/core-ocr/issues"
[tool.isort] [tool.isort]
profile = "black" profile = "black"