Skip to content

Commit 1e10788

Browse files
committed
put lin inside a src dir
1 parent 2f42282 commit 1e10788

File tree

8 files changed

+16
-8
lines changed

8 files changed

+16
-8
lines changed

.envrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
# Add project's bin directory to PATH
33
export PATH="$PWD/bin:$PATH"
44

5+
# Add src directory to PYTHONPATH
6+
export PYTHONPATH="$PWD/src:$PYTHONPATH"
7+
58
# Activate the virtual environment
69
if [ -d ".venv" ]; then
710
source .venv/bin/activate

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ repos:
189189
# # Run the test suite as the last step.
190190
- id: tests
191191
name: Run Test Suite
192-
entry: "poetry run pytest ."
192+
entry: "poetry run pytest"
193193
language: system
194194
pass_filenames: false
195195
always_run: true

pyproject.toml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
requires = ["poetry-core>=2.0.0,<3.0.0"]
33
build-backend = "poetry.core.masonry.api"
44

5+
[tool.poetry]
6+
packages = [{include = "dotcat", from = "src"}]
7+
include = ["templates", "template/**", "LICENSE", "README.md"]
8+
exclude = ["tests"]
9+
510
[project]
611
version = "0.8.26"
712

@@ -85,10 +90,6 @@ testpaths = ["./tests/"]
8590
python_files = ["test_*.py"]
8691
norecursedirs = ["template/py"]
8792

88-
[tool.poetry]
89-
include = ["templates", "template/**", "LICENSE", "README.md"]
90-
exclude = ["tests"]
91-
9293
[tool.virtualenv]
9394
in-project = true
9495
create = true

pytest.ini

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
# pytest.ini
22
[pytest]
3+
pythonpath = src

readthedocs.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,15 @@ version: 2
33
sphinx:
44
configuration: docs/conf.py
55

6-
6+
python:
7+
install:
8+
- method: pip
9+
path: .
710

811
build:
912
os: ubuntu-20.04
1013
tools:
11-
python: '3.9'
14+
python: "3.9"
1215

1316
jobs:
1417
post_create_environment:
@@ -18,4 +21,4 @@ build:
1821
- poetry config virtualenvs.create false
1922
post_install:
2023
# Install dependencies
21-
- poetry install --with docs
24+
- poetry install --with docs
File renamed without changes.

0 commit comments

Comments
 (0)