Skip to content

Commit c229e99

Browse files
authored
Update project dev documentation (#51)
## Changes This PR contains some minor updates for the project: - Git should ignore the virtual environment from Hatch. - Workaround an IntelliJ/PyCharm issue by specifying the full path to the python interpreter when running `make dev`. - EditorConfig settings. - Type hints in the README generator to eliminate a warning during `make lint`.
1 parent f97e489 commit c229e99

File tree

5 files changed

+26
-7
lines changed

5 files changed

+26
-7
lines changed

.editorconfig

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Top-most EditorConfig file.
2+
root = true
3+
4+
# Universal settings.
5+
[*]
6+
indent_style = space
7+
indent_size = 4
8+
tab_width = 8
9+
end_of_line = lf
10+
charset = utf-8
11+
trim_trailing_whitespace = true
12+
insert_final_newline = true
13+
14+
[Makefile]
15+
indent_style = tab
16+
indent_size = tab
17+
18+
[*.{json,yml}]
19+
indent_size = 2

.gitignore

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
.idea
1+
.idea/
2+
.venv/
23
*.iml
34
*.pyc
45
.pytest_cache
56
*.egg-info
67
tests/**/build
78
.coverage
89
coverage.xml
9-
pytester.iml
10+
pytester.iml

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ make dev
242242

243243
To use different python version, specify it in `HATCH_PYTHON` variable:
244244
```shell
245-
HATCH_PYTHON=python3.10 make clean dev test
245+
HATCH_PYTHON=$(which python3.10) make clean dev test
246246
```
247247

248248
Configure your IDE to use `.venv/bin/python` from the virtual environment when developing the project:

scripts/gen-readme.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ def overwrite_readme(part, docs):
6161
f.write(new_readme)
6262

6363

64-
def discover_fixtures():
65-
fixtures = []
64+
def discover_fixtures() -> list[Fixture]:
65+
fixtures: list[Fixture] = []
6666
see_also = collections.defaultdict(set)
6767
idx: dict[str, int] = {}
6868
for fixture in P.__all__:

tests/resources/hatchling-whl/pyproject.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,9 @@ requires-python = ">=3.7"
1010
license = "MIT"
1111
keywords = []
1212
authors = [
13-
{ name = "Jonh Doe", email = "[email protected]" },
13+
{ name = "Jonh Doe", email = "[email protected]" },
1414
]
1515
dependencies = []
1616

1717
[tool.hatch.version]
1818
path = "src/hatchling_whl/__about__.py"
19-

0 commit comments

Comments
 (0)