Skip to content

Commit 503e429

Browse files
authored
Merge pull request #41 from jmeridth/jm-catch-up-repo-standards
chore: catch up repo standards
2 parents 211f5bf + 95a1cd5 commit 503e429

File tree

5 files changed

+32
-29
lines changed

5 files changed

+32
-29
lines changed

.github/linters/.markdown-lint.yml

-19
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,4 @@
11
---
2-
###########################
3-
###########################
4-
## Markdown Linter rules ##
5-
###########################
6-
###########################
7-
8-
# Linter rules doc:
9-
# - https://github.com/DavidAnson/markdownlint
10-
#
11-
# Note:
12-
# To comment out a single error:
13-
# <!-- markdownlint-disable -->
14-
# any violations you want
15-
# <!-- markdownlint-restore -->
16-
#
17-
18-
###############
19-
# Rules by id #
20-
###############
212
# line length
223
MD013: false
234
# singe h1

.github/linters/.mypy.ini

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Global options:
2-
31
[mypy]
42
disable_error_code = attr-defined, import-not-found
3+
4+
[mypy-github3.*]
5+
ignore_missing_imports = True

Makefile

+3-1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ lint:
1111
# stop the build if there are Python syntax errors or undefined names
1212
flake8 . --config=.github/linters/.flake8 --count --select=E9,F63,F7,F82 --show-source
1313
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
14-
flake8 . --config=.github/linters/.flake8 --count --exit-zero --max-complexity=100 --max-line-length=150
14+
flake8 . --config=.github/linters/.flake8 --count --exit-zero --max-complexity=15 --max-line-length=150
15+
isort --settings-file=.github/linters/.isort.cfg .
1516
pylint --rcfile=.github/linters/.python-lint --fail-under=9.0 *.py
17+
mypy --config-file=.github/linters/.mypy.ini *.py
1618
black .

README.md

+23-7
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,28 @@ If you need support using this project or have questions about it, please [open
2525

2626
Below are the allowed configuration options:
2727

28+
#### Authentication
29+
30+
This action can be configured to authenticate with GitHub App Installation or Personal Access Token (PAT). If all configuration options are provided, the GitHub App Installation configuration has precedence. You can choose one of the following methods to authenticate:
31+
32+
##### GitHub App Installation
33+
34+
| field | required | default | description |
35+
|-------------------------------|----------|---------|-------------|
36+
| `GH_APP_ID` | True | `""` | GitHub Application ID. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |
37+
| `GH_APP_INSTALLATION_ID` | True | `""` | GitHub Application Installation ID. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |
38+
| `GH_APP_PRIVATE_KEY` | True | `""` | GitHub Application Private Key. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |
39+
40+
##### Personal Access Token (PAT)
41+
42+
| field | required | default | description |
43+
|-------------------------------|----------|---------|-------------|
44+
| `GH_TOKEN` | True | `""` | The GitHub Token used to scan the repository. Must have read access to all repository you are interested in scanning. |
45+
46+
#### Other Configuration Options
47+
2848
| field | required | default | description |
2949
|---------------------------|----------|---------|-------------|
30-
| `GH_TOKEN` | True | "" | The GitHub Token used to scan the repository or organization. Must have write access to all repository you are interested in scanning so that an issue or pull request can be created. |
31-
| `GH_APP_ID` | False | `""` | GitHub Application ID. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |
32-
| `GH_APP_INSTALLATION_ID` | False | `""` | GitHub Application Installation ID. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |
33-
| `GH_APP_PRIVATE_KEY` | False | `""` | GitHub Application Private Key. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |
3450
| `GH_ENTERPRISE_URL` | False | "" | The `GH_ENTERPRISE_URL` is used to connect to an enterprise server instance of GitHub. github.com users should not enter anything here. |
3551
| `ORGANIZATION` | Required to have `ORGANIZATION` or `REPOSITORY` | | The name of the GitHub organization which you want this action to work from. ie. github.com/github would be `github` |
3652
| `REPOSITORY` | Required to have `ORGANIZATION` or `REPOSITORY` | | The name of the repository and organization which you want this action to work from. ie. `github/cleanowners` or a comma separated list of multiple repositories `github/cleanowners,super-linter/super-linter` |
@@ -57,7 +73,7 @@ jobs:
5773
name: cleanowners
5874
runs-on: ubuntu-latest
5975
permissions:
60-
issues: write
76+
issues: write
6177

6278
steps:
6379
- name: Run cleanowners action
@@ -85,7 +101,7 @@ jobs:
85101
name: cleanowners
86102
runs-on: ubuntu-latest
87103
permissions:
88-
issues: write
104+
issues: write
89105

90106
steps:
91107
- name: Run cleanowners action
@@ -117,7 +133,7 @@ jobs:
117133
name: cleanowners
118134
runs-on: ubuntu-latest
119135
permissions:
120-
issues: write
136+
issues: write
121137
122138
steps:
123139
- name: Run cleanowners action

requirements-test.txt

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
black==24.3.0
22
flake8==7.0.0
3+
mypy==1.8.0
4+
mypy-extensions==1.0.0
35
pylint==3.1.0
46
pytest==8.1.1
57
pytest-cov==5.0.0
8+
types-requests==2.31.0.20240311

0 commit comments

Comments
 (0)