Skip to content

Commit 2a2bad7

Browse files
authored
Update bootstrap with latest changes (#3)
1 parent d071fc7 commit 2a2bad7

File tree

5 files changed

+29
-7
lines changed

5 files changed

+29
-7
lines changed

.replit

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
run = ["pytest", "test_something.py"]
1+
run = ["make", "test"]
22
language = "python3"
3-
entrypoint = "test_something.py"
3+
entrypoint = "main.py"
44
hidden = ["LICENSE", "venv", ".config", ".gitignore", "**/__pycache__", "**/.pytest_cache", "**/*.pyc"]
55

66
[nix]

Makefile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
.PHONY: run
2+
run:
3+
./main.py
4+
5+
.PHONY: test
6+
test:
7+
pytest test_*.py
8+
9+
ifndef VERBOSE
10+
.SILENT:
11+
endif

README.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,26 @@
44

55
## Overview
66

7-
This is a bootstrap repository for clean code katas in Python 3.
7+
This is a bootstrap repository for clean code katas in Python 3 using pytest.
88

99
## Usage
1010

11-
You can import this project into [Replit](https://replit.com)
12-
and it will handle all dependencies automatically.
11+
You can import this project into [Replit](https://replit.com), and it will
12+
handle all dependencies automatically.
1313

1414
### Prerequisites
1515

1616
* [Python 3.8+](https://www.python.org/)
1717
* [pytest](https://pytest.org)
1818

19+
### Run main
20+
21+
```console
22+
make run
23+
```
24+
1925
### Run tests
2026

2127
```console
22-
pytest test_something.py
28+
make test
2329
```

main.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/usr/bin/env python3
2+
3+
if __name__ == "__main__":
4+
print("Hello World!")

replit.nix

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{ pkgs }: {
22
deps = [
33
pkgs.python38Full
4+
pkgs.python38Packages.pytest
45
];
56
env = {
67
PYTHON_LD_LIBRARY_PATH = pkgs.lib.makeLibraryPath [
@@ -13,4 +14,4 @@
1314
PYTHONBIN = "${pkgs.python38Full}/bin/python3.8";
1415
LANG = "en_US.UTF-8";
1516
};
16-
}
17+
}

0 commit comments

Comments
 (0)