-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add: Add README for mypy-python action
- Loading branch information
1 parent
ca5d8a7
commit 6124190
Showing
1 changed file
with
35 additions
and
0 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,35 @@ | ||
# Mypy Python Action | ||
|
||
GitHub Action to check typings in Python project with [mypy]. | ||
|
||
## Example | ||
|
||
```yml | ||
name: Type checking | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
lint-python: | ||
name: Setup and lint project | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: greenbone/actions/mypy-python@v2 | ||
with: | ||
packages: my_project tests | ||
``` | ||
## Action Configuration | ||
|Input Variable|Description| | | ||
|--------------|-----------|-| | ||
| packages | Python packages to check | Required | | ||
| mypy-arguments | Additional arguments to mypy | Optional | | ||
| python-version | Python version to use for running the action. | Optional (default is `3.10`) | | ||
| poetry-version | Use a specific poetry version. By default the latest release is used. | Optional (default latest poetry version) | | ||
| cache | Cache dependencies by setting it to `"true"`. Leave unset or set to an other string then `"true"` to disable the cache. | Optional | | ||
| cache-dependency-path | Used to specify the path to dependency files. Supports wildcards or a list of file names for caching multiple dependencies. | Optional | | ||
| cache-poetry-installation | "Cache poetry and its dependencies. Default is `"true"`. Set to an other string then `"true"` to disable the cache." | Optional (default: `"true"`) | | ||
|
||
[mypy]: https://mypy.readthedocs.io/en/stable/ |