1 parent
0ff0efd8d7
commit
430fbafc02
4 files changed
+75
-12
No files matched your search
@@ -0,0 +1,31 @@
|
||||
name: Compile Card DB
|
||||
|
||||
on: push
|
||||
|
||||
jobs:
|
||||
compile_card_db:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.8
|
||||
- run: |
|
||||
pip install -r requirements.txt
|
||||
pip install .
|
||||
- name: Update Languages
|
||||
run: doit update_languages
|
||||
- uses: dorny/paths-filter@v2
|
||||
id: filter
|
||||
with:
|
||||
base: HEAD
|
||||
filters: |
|
||||
cardb_target:
|
||||
- src/domdiv/card_db/**
|
||||
- name: Commit Results
|
||||
if: steps.filter.outputs.cardb_target == 'true'
|
||||
run: |
|
||||
git config --global user.name 'Github Action: Compile Card DB'
|
||||
git config --global user.email 'sumpfork@users.noreply.github.com'
|
||||
git commit -am "Compile Card DB"
|
||||
git push
|
||||
@@ -0,0 +1,18 @@
|
||||
name: Lint and Test
|
||||
|
||||
on: push
|
||||
|
||||
jobs:
|
||||
lint_and_test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.8
|
||||
- run: |
|
||||
pip install -r requirements.txt
|
||||
- name: Lint
|
||||
run: pre-commit run --all-files
|
||||
- name: Test
|
||||
run: python setup.py test
|
||||
@@ -0,0 +1,26 @@
|
||||
name: Upload Python Package
|
||||
|
||||
on:
|
||||
release:
|
||||
types: [created]
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.x'
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install setuptools wheel twine
|
||||
- name: Build and publish
|
||||
env:
|
||||
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
|
||||
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
|
||||
run: |
|
||||
python setup.py sdist bdist_wheel
|
||||
twine upload dist/*
|
||||
Reference in new issue
Block a user