parent
0ff0efd8d7
commit
430fbafc02
31
.github/workflows/compile_card_db.yml
vendored
Normal file
31
.github/workflows/compile_card_db.yml
vendored
Normal file
@ -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
|
||||||
18
.github/workflows/lint_and_test.yml
vendored
Normal file
18
.github/workflows/lint_and_test.yml
vendored
Normal file
@ -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
|
||||||
26
.github/workflows/publish.yml
vendored
Normal file
26
.github/workflows/publish.yml
vendored
Normal file
@ -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/*
|
||||||
12
.travis.yml
12
.travis.yml
@ -2,24 +2,12 @@ language: python
|
|||||||
python:
|
python:
|
||||||
- '3.8'
|
- '3.8'
|
||||||
install:
|
install:
|
||||||
- python setup.py install_egg_info
|
|
||||||
- pip install -U setuptools
|
- pip install -U setuptools
|
||||||
- pip install -r requirements.txt
|
- pip install -r requirements.txt
|
||||||
- pip install .
|
- pip install .
|
||||||
script:
|
script:
|
||||||
- python setup.py test
|
- python setup.py test
|
||||||
- if [[ ${TRAVIS_PYTHON_VERSION:0:1} == "3" ]]; then pre-commit run --all-files; fi
|
- if [[ ${TRAVIS_PYTHON_VERSION:0:1} == "3" ]]; then pre-commit run --all-files; fi
|
||||||
- doit update_languages
|
|
||||||
after_success:
|
|
||||||
- git diff
|
|
||||||
- git status
|
|
||||||
- git diff-index HEAD --
|
|
||||||
- if ! git diff-index --quiet HEAD --; then .travis/push.sh; fi
|
|
||||||
- echo $TRAVIS_TAG
|
|
||||||
- git clean -df
|
|
||||||
- git diff-index HEAD --
|
|
||||||
- git diff
|
|
||||||
- git status
|
|
||||||
deploy:
|
deploy:
|
||||||
provider: pypi
|
provider: pypi
|
||||||
user: __token__
|
user: __token__
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user