-
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.
* fix: type checking * chore: cleanups * fix: faster startup * chore: update poetry in cicd
- Loading branch information
Showing
21 changed files
with
765 additions
and
1,052 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: "coverage.io" | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
|
||
jobs: | ||
build: | ||
name: Test Build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Install poetry | ||
run: pipx install poetry==1.3.2 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
cache: "poetry" | ||
- name: Install system deps | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install \ | ||
libgirepository1.0-dev \ | ||
libcairo2-dev \ | ||
python3-gi \ | ||
gobject-introspection \ | ||
libgtk-3-dev | ||
- name: Poetry install | ||
run: poetry install | ||
- name: Pytest | ||
run: poetry run pytest --cov --cov-report=xml | ||
- name: Coveralls | ||
run: poetry run coveralls | ||
env: | ||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_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,89 @@ | ||
name: Test | ||
on: [push, pull_request] | ||
|
||
concurrency: | ||
group: cicd-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
test: | ||
name: Test on Linux64 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Install poetry | ||
run: pipx install poetry==1.3.2 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
cache: "poetry" | ||
- name: Install system deps | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install \ | ||
libgirepository1.0-dev \ | ||
libcairo2-dev \ | ||
python3-gi \ | ||
gobject-introspection \ | ||
libgtk-4-dev | ||
- name: Poetry install | ||
run: poetry install | ||
- name: Ruff | ||
run: poetry run ruff check . | ||
- name: Black | ||
run: poetry run black --check . | ||
- name: Isort | ||
run: poetry run isort --check . | ||
- name: Mypy | ||
run: poetry run mypy | ||
- name: Pytest | ||
run: poetry run pytest | ||
- name: Test AppImage build | ||
run: poetry run make clean-build | ||
|
||
publish: | ||
name: Build & Publish | ||
needs: test | ||
if: startsWith(github.ref, 'refs/tags/v') | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Install poetry | ||
run: pipx install poetry==1.3.2 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
cache: "poetry" | ||
- name: Install system deps | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install \ | ||
libgirepository1.0-dev \ | ||
libcairo2-dev \ | ||
python3-gi \ | ||
gobject-introspection \ | ||
libgtk-3-dev | ||
- name: Poetry install | ||
run: poetry install | ||
# Prepare Release | ||
- name: Build AppImage | ||
run: poetry run make clean-build | ||
- name: Draft release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
files: | | ||
*.AppImage | ||
body: | ||
See [CHANGELOG](https://github.com/dynobo/keyhint/blob/main/CHANGELOG) for | ||
details. | ||
draft: true | ||
prerelease: true | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
# Publish to PyPi | ||
- name: Build and publish to PyPi | ||
run: | | ||
poetry publish \ | ||
--build \ | ||
--username __token__ \ | ||
--password ${{ secrets.PYPI_KEYHINT_TOKEN }} |
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.