Skip to content

Commit

Permalink
chore: Prepare to make public (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarrmondragon authored Sep 2, 2023
1 parent 077749d commit 1e49c43
Show file tree
Hide file tree
Showing 5 changed files with 248 additions and 124 deletions.
53 changes: 53 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Publish with Dynamic Versioning

on:
release:
types: [published]

permissions:
contents: write
id-token: write

jobs:
publish:
name: Publish to PyPI
runs-on: ubuntu-latest
environment: publishing
env:
PIP_CONSTRAINT: .github/workflows/constraints.txt
steps:
- name: Checkout code
uses: actions/checkout@v3.6.0
with:
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v4.7.0
with:
python-version: "3.10"

- name: Upgrade pip
run: |
pip install pip
pip --version
- name: Install Poetry
run: |
pipx install poetry
pipx inject poetry poetry-dynamic-versioning[plugin]
poetry --version
poetry self show plugins
- name: Build
run: poetry build

- name: Upload wheel to release
uses: svenstaro/upload-release-action@v2
with:
file: dist/*.whl
tag: ${{ github.ref }}
overwrite: true
file_glob: true

- name: Publish
uses: pypa/gh-action-pypi-publish@v1.8.8
20 changes: 1 addition & 19 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
SETUPTOOLS_USE_DISTUTILS: stdlib
strategy:
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
python-version: ["3.8", "3.9", "3.10", "3.11"]

steps:
- name: Checkout code
Expand Down Expand Up @@ -67,21 +67,3 @@ jobs:
TAP_GEEKBOT_START_DATE: ${{ secrets.TAP_GEEKBOT_START_DATE }}
run: |
nox
pre-commit:
runs-on: ubuntu-latest
env:
FORCE_COLOR: "1"
steps:
- name: Checkout code
uses: actions/checkout@v3.6.0

- name: Set up Python
uses: actions/setup-python@v4.7.0
with:
python-version: "3.11"

- uses: pre-commit/action@v3.0.0

- uses: pre-commit-ci/lite-action@v1.0.1
if: always()
12 changes: 9 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
ci:
autofix_prs: true
autofix_commit_msg: "[pre-commit.ci] auto fixes"
autoupdate_schedule: monthly
autoupdate_commit_msg: "ci(deps-dev): pre-commit autoupdate"

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
Expand All @@ -10,12 +16,12 @@ repos:
- id: trailing-whitespace

- repo: https://github.com/tox-dev/pyproject-fmt
rev: "0.13.1"
rev: "1.1.0"
hooks:
- id: pyproject-fmt

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.0.284"
rev: "v0.0.287"
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix, --show-fixes]
Expand All @@ -26,7 +32,7 @@ repos:
- id: black

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.5.0
rev: v1.5.1
hooks:
- id: mypy
pass_filenames: true
Expand Down
Loading

0 comments on commit 1e49c43

Please sign in to comment.