Add template files
This commit is contained in:
32
.github/workflows/python-publish.yml
vendored
Executable file
32
.github/workflows/python-publish.yml
vendored
Executable file
@@ -0,0 +1,32 @@
|
||||
name: Release and Publish Python Package
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*"
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.11'
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip build
|
||||
- name: Build package
|
||||
run: |
|
||||
python3 -m build --sdist --wheel --outdir dist/ .
|
||||
- name: Publish package
|
||||
uses: pypa/gh-action-pypi-publish@release/v1
|
||||
- name: Create GitHub release
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
files: |
|
||||
dist/*
|
||||
@@ -1,2 +1,3 @@
|
||||
# python-package-template
|
||||
A template for Python project to be published on PyPI with setuptools, python-build, PyPI trusted publisher and github actions auto release.
|
||||
|
||||
A template for Python project to be published on PyPI with setuptools, python-build, PyPI trusted publishing and github actions auto release.
|
||||
|
||||
19
pyproject.toml
Normal file
19
pyproject.toml
Normal file
@@ -0,0 +1,19 @@
|
||||
[project]
|
||||
# name = "Project name..."
|
||||
# version = "Project version, e.g. 0.0.1"
|
||||
# description = "Project description..."
|
||||
# authors = [
|
||||
# {name = "Author name", email = "Author email"},
|
||||
# ...
|
||||
# ]
|
||||
# license = {text = "Project license on PyPI, e.g. MIT"}
|
||||
# dependencies = ["dependency1...", "dependency2...", ...]
|
||||
# requires-python = ">=3.9"
|
||||
readme = "README.md"
|
||||
|
||||
[project.urls]
|
||||
# Homepage = "https://github.com/..."
|
||||
# Repository = "https://github.com/..."
|
||||
|
||||
[tool.pyright]
|
||||
pythonVersion = "3.9"
|
||||
Reference in New Issue
Block a user