This repository was archived by the owner on Apr 3, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 133
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #60 from chorsley/gh-actions
Gh actions
- Loading branch information
Showing
6 changed files
with
104 additions
and
56 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
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,72 @@ | ||
name: Tests (and release on tags) | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
tags: | ||
- '*' | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
unit_tests: | ||
runs-on: ${{ matrix.os }} | ||
|
||
strategy: | ||
matrix: | ||
python-version: [3.6, 3.7, 3.8, 3.9] | ||
os: [ubuntu-20.04] | ||
include: | ||
- os: windows-latest | ||
python-version: 3.6 | ||
- os: macos-latest | ||
python-version: 3.6 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install tox | ||
run: | | ||
python -m pip install --upgrade pip tox | ||
- name: Run unit tests | ||
run: | | ||
tox -e test | ||
- name: Run static code checks | ||
run: | | ||
tox -e mypy | ||
release: | ||
|
||
needs: [unit_tests] | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Python 3.9 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Install deps | ||
run: | | ||
python -m pip install --upgrade pip setuptools wheel | ||
- name: Build python-Wappalyzer | ||
run: | | ||
python setup.py --quiet build check sdist bdist_wheel | ||
ls -alh ./dist/ | ||
- name: Publish python-Wappalyzer to PyPI on tags | ||
if: startsWith(github.ref, 'refs/tags') | ||
uses: pypa/gh-action-pypi-publish@master | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.PYPI_TOKEN }} |
This file was deleted.
Oops, something went wrong.
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
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
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