Skip to content

Commit 20141dd

Browse files
even-evenvyuroshchinwoodruffw
authored
add more rules in pre-commits (#985)
Co-authored-by: vyuroshchin <vyuroshchin@sberautotech.ru> Co-authored-by: William Woodruff <william@yossarian.net>
1 parent 3c47ca5 commit 20141dd

File tree

7 files changed

+20
-55
lines changed

7 files changed

+20
-55
lines changed

.github/workflows/release.yml

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,19 @@ jobs:
1919
contents: write
2020

2121
steps:
22-
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
23-
with:
24-
persist-credentials: false
22+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
23+
with:
24+
persist-credentials: false
2525

26-
- uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
27-
with:
28-
python-version-file: pyproject.toml
26+
- uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
27+
with:
28+
python-version-file: pyproject.toml
2929

30-
- name: deps
31-
run: python -m pip install -U build
30+
- name: deps
31+
run: python -m pip install -U build
3232

33-
- name: build
34-
run: python -m build
35-
36-
- name: publish
37-
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0
33+
- name: build
34+
run: python -m build
3835

36+
- name: publish
37+
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0

.github/workflows/scorecards.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ on:
55
schedule:
66
- cron: '19 4 * * 0'
77
push:
8-
branches: [ "main" ]
8+
branches: ["main"]
99

1010
# No permissions needed at top-level.
1111
permissions: {}

.pre-commit-config.yaml

Lines changed: 0 additions & 36 deletions
This file was deleted.

Makefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ PY_MODULE := pip_audit
55
ALL_PY_SRCS := $(shell find $(PY_MODULE) -name '*.py') \
66
$(shell find test -name '*.py')
77

8-
# Optionally overriden by the user, if they're using a virtual environment manager.
8+
# Optionally overridden by the user, if they're using a virtual environment manager.
99
VENV ?= env
1010

1111
# On Windows, venv scripts/shims are under `Scripts` instead of `bin`.
@@ -52,7 +52,8 @@ lint: $(VENV)/pyvenv.cfg
5252
ruff format --check $(ALL_PY_SRCS) && \
5353
ruff check $(ALL_PY_SRCS) && \
5454
mypy $(PY_MODULE) && \
55-
interrogate -c pyproject.toml .
55+
interrogate -c pyproject.toml . && \
56+
typos .
5657

5758
.PHONY: reformat
5859
reformat:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,7 @@ and purposes, `pip-audit -r INPUT` is functionally equivalent to
604604
`pip install -r INPUT`, with a small amount of **non-security isolation** to
605605
avoid conflicts with any of your local environments.
606606

607-
`pip-audit` is first and foremost a auditing tool for *Python* packages.
607+
`pip-audit` is first and foremost an auditing tool for *Python* packages.
608608
You **must not** assume that `pip-audit` will detect or flag "transitive"
609609
vulnerabilities that might be exposed through Python packages, but are not
610610
actually part of the package itself. For example, `pip-audit`'s vulnerability

pyproject.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,12 @@ cov = [
4646
]
4747
test = ["pretend", "pytest", "pip-audit[cov]"]
4848
lint = [
49-
"ruff >= 0.11",
49+
"ruff >= 0.14",
5050
"interrogate ~= 1.6",
5151
"mypy",
5252
"types-requests",
5353
"types-toml",
54+
"typos",
5455
]
5556
doc = ["pdoc"]
5657
dev = ["build", "pip-audit[doc,test,lint]"]

test/dependency_source/test_requirement.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -697,7 +697,7 @@ def test_requirement_source_fix_explicit_subdep_resolver_error(req_file):
697697
assert len(mock_resolver.resolve.calls) == 0
698698

699699

700-
def test_requirement_source_fix_explicit_subdep_comment_retension(req_file):
700+
def test_requirement_source_fix_explicit_subdep_comment_retention(req_file):
701701
# This test is regression testing a weakness in the previous fix implementation.
702702
#
703703
# When fixing a subdependency and explicitly adding it to the requirements file, we add a

0 commit comments

Comments
 (0)