-
-
Notifications
You must be signed in to change notification settings - Fork 0
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
Cariad Eccleston
authored
Dec 7, 2020
1 parent
1a7742a
commit efa54df
Showing
64 changed files
with
2,370 additions
and
2 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,8 @@ | ||
[run] | ||
command_line = -m pytest | ||
omit = | ||
*/test_*.py | ||
source = wev | ||
|
||
[report] | ||
fail_under = 89 |
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,14 @@ | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 4 | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.sh] | ||
indent_size = 2 | ||
|
||
[*.yml] | ||
indent_size = 2 |
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: wev | ||
|
||
on: # yamllint disable-line rule:truthy | ||
- push | ||
|
||
jobs: | ||
|
||
build: | ||
container: cariad/ci:1.0.0 | ||
runs-on: ubuntu-20.04 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Sync dependencies | ||
run: pipenv sync --dev | ||
|
||
- name: Test | ||
run: pipenv run ./test.sh | ||
|
||
- name: Version | ||
run: echo "${GITHUB_REF##*/}" > wev/VERSION | ||
|
||
- name: Build | ||
run: pipenv run ./build.sh | ||
|
||
- name: Archive distributable | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: distributable | ||
path: dist | ||
retention-days: 1 | ||
|
||
cli_test: | ||
name: CLI test (Python ${{ matrix.python-version }}) | ||
needs: build | ||
runs-on: ubuntu-20.04 | ||
strategy: | ||
matrix: | ||
python-version: | ||
- "3.8" | ||
- "3.9" | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Download build distributable | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: distributable | ||
|
||
- name: Install distributable | ||
run: pip install "$(ls *.whl)" | ||
|
||
- name: Assert version | ||
run: | | ||
wev --version | tee version.tmp | ||
grep -qF "${GITHUB_REF##*/}" version.tmp | ||
publish: | ||
if: startsWith(github.ref, 'refs/tags') | ||
needs: build | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Download build distributable | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: distributable | ||
|
||
- name: Create distributable directory | ||
run: | | ||
mkdir dist | ||
cp *.whl dist | ||
ls -al dist/ | ||
- name: Publish | ||
uses: pypa/gh-action-pypi-publish@v1.4.1 | ||
with: | ||
user: __token__ | ||
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,11 @@ | ||
*.egg-info | ||
__*__ | ||
.DS_Store | ||
.coverage | ||
.mypy_cache | ||
.pytest_cache | ||
.vscode | ||
build | ||
dist | ||
htmlcov | ||
typing-coverage.xml |
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,8 @@ | ||
extends: default | ||
|
||
rules: | ||
document-start: disable | ||
line-length: | ||
allow-non-breakable-inline-mappings: true | ||
allow-non-breakable-words: true | ||
max: 80 |
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 @@ | ||
include wev/VERSION |
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,23 @@ | ||
[[source]] | ||
name = "pypi" | ||
url = "https://pypi.org/simple" | ||
verify_ssl = true | ||
|
||
[dev-packages] | ||
black = "==20.8b1" | ||
coverage = "~=5.3" | ||
flake8 = "~=3.8" | ||
isort = "~=5.5" | ||
mock = "~=4.0" | ||
mypy = "~=0.790" | ||
pytest = "~=6.1" | ||
yamllint = "~=1.25" | ||
|
||
[packages] | ||
colorama = "~=0.4" | ||
dwalk = "~=1.1" | ||
pytz = "*" | ||
"ruamel.yaml" = "~=0.16" | ||
|
||
[requires] | ||
python_version = "3.9" |
Oops, something went wrong.