mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-09-10 23:00:12 +02:00
Merge branch 'vscode' into 'master'
add vscode settings Closes #909 See merge request fdroid/fdroidserver!965
This commit is contained in:
commit
1236f89896
3
.bandit
Normal file
3
.bandit
Normal file
@ -0,0 +1,3 @@
|
||||
[bandit]
|
||||
skips: B110,B404,B408,B410,B603,B607
|
||||
targets: .
|
@ -181,9 +181,9 @@ lint_format_safety_bandit_checks:
|
||||
- function set_error() { export EXITVALUE=1; printf "\x1b[31mERROR `history|tail -2|head -1|cut -b 6-500`\x1b[0m\n"; }
|
||||
- ./hooks/pre-commit || set_error
|
||||
- bandit
|
||||
-r
|
||||
-ii
|
||||
-s B110,B404,B408,B410,B603,B607
|
||||
-r $CI_PROJECT_DIR fdroid
|
||||
--ini .bandit
|
||||
|| set_error
|
||||
- safety check --full-report || set_error
|
||||
- pylint --rcfile=.pylint-rcfile --output-format=colorized --reports=n
|
||||
@ -213,8 +213,7 @@ lint_mypy:
|
||||
python3-pip
|
||||
python3-wheel
|
||||
- pip install -e .[test]
|
||||
# exclude vendored file
|
||||
- mypy --exclude fdroidserver/apksigcopier.py
|
||||
- mypy
|
||||
|
||||
|
||||
fedora_latest:
|
||||
|
5
.vscode/extensions.json
vendored
Normal file
5
.vscode/extensions.json
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"recommendations": [
|
||||
"ms-python.python",
|
||||
]
|
||||
}
|
22
.vscode/settings.json
vendored
Normal file
22
.vscode/settings.json
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
{
|
||||
"python.formatting.blackArgs": [
|
||||
"--config pyproject.toml"
|
||||
],
|
||||
"python.formatting.provider": "black",
|
||||
"python.linting.banditEnabled": true,
|
||||
"python.linting.banditArgs": [
|
||||
"-r",
|
||||
"-ii",
|
||||
"--ini .bandit",
|
||||
],
|
||||
"python.linting.enabled": true,
|
||||
"python.linting.mypyArgs": [
|
||||
"--config-file mypy.ini"
|
||||
],
|
||||
"python.linting.mypyEnabled": true,
|
||||
"python.linting.pycodestyleEnabled": true,
|
||||
"python.linting.pylintArgs": [
|
||||
"--rcfile=.pylint-rcfile"
|
||||
],
|
||||
"python.linting.pylintEnabled": true,
|
||||
}
|
4
mypy.ini
4
mypy.ini
@ -1,5 +1,7 @@
|
||||
[mypy]
|
||||
files = fdroidserver
|
||||
# exclude vendored file
|
||||
exclude = fdroidserver/apksigcopier.py
|
||||
|
||||
# this is de-facto the linter setting for this file
|
||||
warn_unused_configs = True
|
||||
@ -12,4 +14,4 @@ ignore_missing_imports = True
|
||||
# unfortunately both tools expect their ignore flag as a comment in the same line
|
||||
# [misc] is ignored for the "incompatible import"
|
||||
# [arg-type] is ignored because when there are missing envs, everything will crash, not just the types
|
||||
disable_error_code = no-redef, misc, arg-type
|
||||
disable_error_code = no-redef, misc, arg-type
|
||||
|
2
pyproject.toml
Normal file
2
pyproject.toml
Normal file
@ -0,0 +1,2 @@
|
||||
[tool.black]
|
||||
skip-string-normalization = true
|
Loading…
Reference in New Issue
Block a user