Skip to content

Commit 1c892e2

Browse files
committed
Use Nix
1 parent 1bcbcc6 commit 1c892e2

File tree

4 files changed

+31
-8
lines changed

4 files changed

+31
-8
lines changed

.justfile

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,3 @@ check:
4343
# Add scripts
4444
add_scripts:
4545
uv add --script scripts/this.py 'typer>=0.12.5'
46-
47-
# Build dockerfile for DAG
48-
build target:
49-
docker build -t packages/{{target}} --build-arg PACKAGE={{target}} .

README.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ A web dashboard for training machine learning models with PyTorch.
3131
[![Python][Python-shield]][Python-url]
3232
[![Pytest][Pytest-shield]][Pytest-url]
3333
[![Codecov][Codecov-shield]][Codecov-url]
34-
[![Docker][Docker-shield]][Docker-url]
34+
[![NixOS][NixOS-shield]][NixOS-url]
3535
[![GitHub Actions][github-actions-shield]][github-actions-url]
3636

3737
<!-- GETTING STARTED -->
@@ -56,6 +56,7 @@ To get a local copy of the project up and running on your machine, follow these
5656
2. Install the virtual environment and pre-commit hooks
5757

5858
```sh
59+
nix-shell
5960
just install
6061
```
6162

@@ -73,6 +74,8 @@ To get a local copy of the project up and running on your machine, follow these
7374
just run <package_name>
7475
```
7576

77+
The dashboard will be available at `http://localhost:8000`.
78+
7679
<!-- PROJECT FILE STRUCTURE -->
7780

7881
## Project Structure
@@ -113,8 +116,8 @@ The source code for this project is distributed under the terms of the MIT Licen
113116
[Python-url]: https://www.python.org/
114117
[Pytest-shield]: https://img.shields.io/badge/pytest-%23008080.svg?style=for-the-badge&logo=pytest&logoColor=2F9FE3&labelColor=222222&color=2F9FE3
115118
[Pytest-url]: https://docs.pytest.org
116-
[Docker-shield]: https://img.shields.io/badge/docker-%232671E5.svg?style=for-the-badge&logo=docker&logoColor=1D63ED&labelColor=222222&color=1D63ED
117-
[Docker-url]: https://www.docker.com/
119+
[NixOS-shield]: https://img.shields.io/badge/NIX-%23008080.svg?style=for-the-badge&logo=NixOS&logoColor=5277C3&labelColor=222222&color=5277C3
120+
[NixOS-url]: https://nixos.org/
118121
[Codecov-shield]: https://img.shields.io/badge/codecov-%23008080.svg?style=for-the-badge&logo=codecov&logoColor=FF0077&labelColor=222222&color=FF0077
119122
[Codecov-url]: https://codecov.io/
120123
[github-actions-shield]: https://img.shields.io/badge/github%20actions-%232671E5.svg?style=for-the-badge&logo=githubactions&logoColor=2671E5&labelColor=222222&color=2671E5

pyproject.toml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,19 @@ skips = ['B101']
6464

6565
[tool.ruff]
6666
lint.ignore = ["E501"]
67-
extend-exclude = ["__pycache__", "docs", "site", ".tmp"]
67+
extend-exclude = [
68+
"__pycache__",
69+
"docs",
70+
"site",
71+
".eggs",
72+
".git",
73+
".venv",
74+
"build",
75+
"dist",
76+
"notebooks",
77+
".cache",
78+
]
79+
line-length = 100
6880

6981
[tool.pytest.ini_options]
7082
cache_dir = ".pytest_cache"

shell.nix

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{ pkgs ? import <nixpkgs> { } }:
2+
3+
pkgs.mkShell {
4+
buildInputs = [
5+
pkgs.just # Just
6+
pkgs.uv # Python package manager
7+
pkgs.python311 # Python 3.11
8+
];
9+
10+
# Shell hook to set up environment
11+
shellHook = "";
12+
}

0 commit comments

Comments
 (0)