-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
106 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# SPDX-FileCopyrightText: 2021 Jeff Epler | ||
# | ||
# SPDX-License-Identifier: MIT | ||
|
||
name: Release chap | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
release: | ||
|
||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Dump GitHub context | ||
env: | ||
GITHUB_CONTEXT: ${{ toJson(github) }} | ||
run: echo "$GITHUB_CONTEXT" | ||
|
||
- uses: actions/checkout@v3 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Install deps | ||
run: | | ||
python -mpip install wheel | ||
python -mpip install -r requirements-dev.txt | ||
- name: Test | ||
run: make coverage | ||
|
||
- name: Build release | ||
run: python -mbuild | ||
|
||
- name: Upload release | ||
run: twine upload -u "$TWINE_USERNAME" -p "$TWINE_PASSWORD" dist/* | ||
env: | ||
TWINE_USERNAME: __token__ | ||
TWINE_PASSWORD: ${{ secrets.pypi_token }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# SPDX-FileCopyrightText: 2021 Jeff Epler | ||
# | ||
# SPDX-License-Identifier: MIT | ||
|
||
name: Test | ||
|
||
on: | ||
push: | ||
pull_request: | ||
release: | ||
types: [published] | ||
check_suite: | ||
types: [rerequested] | ||
|
||
jobs: | ||
pre-commit: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
|
||
- uses: actions/checkout@v3 | ||
|
||
- name: pre-commit | ||
uses: pre-commit/[email protected] | ||
|
||
- name: Make patch | ||
if: failure() | ||
run: git diff > ~/pre-commit.patch | ||
|
||
- name: Upload patch | ||
if: failure() | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: patch | ||
path: ~/pre-commit.patch | ||
|
||
test-release: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: install deps | ||
run: pip install -r requirements-dev.txt | ||
|
||
- name: Build release | ||
run: python -mbuild | ||
|
||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: dist | ||
path: dist/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# SPDX-FileCopyrightText: 2023 Jeff Epler | ||
# | ||
# SPDX-License-Identifier: MIT | ||
|
||
build | ||
setuptools>=45 | ||
wheel |