-
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use github-ci instead of Travis and Appveyor (#355)
- Loading branch information
1 parent
a9f6de6
commit ad58857
Showing
4 changed files
with
142 additions
and
90 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,58 @@ | ||
name: Python package | ||
|
||
on: [release] | ||
|
||
jobs: | ||
|
||
documents: | ||
strategy: | ||
max-parallel: 4 | ||
matrix: | ||
python-version: [3.7] | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@master | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v1 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip setuptools | ||
python -m pip install -r requirements/docs.txt | ||
- name: Deploy documents | ||
env: | ||
GH_TOKEN: ${{ secrets.GH_DEPLOY_KEY }} | ||
GH_USER: ${{ secrets.GH_USER }} | ||
GH_EMAIL: ${{ secrets.GH_EMAIL }} | ||
run: | | ||
git config user.name ${GH_USER} | ||
git config user.email "${GH_EMAIL}" | ||
git remote add gh-token "https://${GH_TOKEN}@github.com/facelessuser/Rummage.git" | ||
git fetch gh-token && git fetch gh-token gh-pages:gh-pages | ||
python -m mkdocs gh-deploy -v --clean --remote-name gh-token | ||
git push gh-token gh-pages | ||
sdist: | ||
strategy: | ||
matrix: | ||
python-version: [3.7] | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@master | ||
- uses: actions/setup-python@v1 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Package | ||
run: | | ||
pip install --upgrade setuptools | ||
python setup.py sdist | ||
- name: Publish | ||
uses: pypa/gh-action-pypi-publish@master | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.PYPI_PWD }} |
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,84 @@ | ||
name: Python package | ||
|
||
on: [push] | ||
|
||
jobs: | ||
tests: | ||
strategy: | ||
fail-fast: false | ||
max-parallel: 4 | ||
matrix: | ||
platform: [ubuntu-latest, windows-latest] | ||
python-version: [3.5, 3.6, 3.7] | ||
|
||
runs-on: ${{ matrix.platform }} | ||
|
||
steps: | ||
- uses: actions/checkout@master | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v1 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip setuptools tox coverage codecov | ||
python -m pip install -r requirements/test.txt | ||
python -m pip install -r requirements/test-project.txt | ||
python -m pip install -r requirements/setup.txt | ||
- name: Test with pytest | ||
run: | | ||
python -m pytest --cov rummage --cov-append tests | ||
python -m coverage html -d coverage | ||
python -m coverage report --show-missing | ||
- name: Coverage Report | ||
if: success() | ||
run: | | ||
python -m codecov -t ${{ secrets.CODECOV_TOKEN }} | ||
lint: | ||
strategy: | ||
max-parallel: 4 | ||
matrix: | ||
python-version: [3.7] | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@master | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v1 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip setuptools | ||
python -m pip install -r requirements/lint.txt | ||
- name: Lint | ||
run: | | ||
python -m flake8 . | ||
documents: | ||
strategy: | ||
max-parallel: 4 | ||
matrix: | ||
python-version: [3.7] | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@master | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v1 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip setuptools | ||
python -m pip install -r requirements/docs.txt | ||
- name: Install Aspell | ||
run: | | ||
sudo apt-get install aspell aspell-en | ||
- name: Build documents | ||
run: | | ||
python -m mkdocs build --clean --verbose --strict | ||
python -m pyspelling |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.