forked from cjolowicz/cookiecutter-hypermodern-python
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add SonarCloud config and GitHub actions (#14)
- Remove support for Python 3.8
- Loading branch information
1 parent
482325d
commit eabcbb1
Showing
7 changed files
with
241 additions
and
219 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 |
---|---|---|
@@ -1,8 +1,6 @@ | ||
name: Tests | ||
|
||
on: | ||
- push | ||
- pull_request | ||
on: [push, pull_request] | ||
|
||
jobs: | ||
tests: | ||
|
@@ -17,11 +15,9 @@ jobs: | |
- { python: "3.11", os: "ubuntu-latest", session: "mypy" } | ||
- { python: "3.10", os: "ubuntu-latest", session: "mypy" } | ||
- { python: "3.9", os: "ubuntu-latest", session: "mypy" } | ||
- { python: "3.8", os: "ubuntu-latest", session: "mypy" } | ||
- { python: "3.11", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.10", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.9", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.8", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.11", os: "windows-latest", session: "tests" } | ||
- { python: "3.11", os: "macos-latest", session: "tests" } | ||
- { python: "3.11", os: "ubuntu-latest", session: "typeguard" } | ||
|
@@ -116,6 +112,8 @@ jobs: | |
steps: | ||
- name: Check out the repository | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis | ||
|
||
- name: Set up Python | ||
uses: actions/[email protected] | ||
|
@@ -153,3 +151,11 @@ jobs: | |
- name: Upload coverage report | ||
uses: codecov/[email protected] | ||
|
||
- name: SonarCloud Scan | ||
env: | ||
GITHUB_TOKEN: {{ "${{ secrets.GITHUB_TOKEN }}" }} # Needed to get PR information, if any | ||
SONAR_TOKEN: {{ "${{ secrets.SONAR_TOKEN }}" }} | ||
# No need to run SonarCloud analysis if dependabot update or token not defined | ||
if: env.SONAR_TOKEN != '' && (github.actor != 'dependabot[bot]') | ||
uses: SonarSource/[email protected] |
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.