Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📦 setup Python packaging #92

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
use flake
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
.direnv

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
Expand Down Expand Up @@ -101,4 +103,4 @@ venv.bak/
/site

# mypy
.mypy_cache/
.mypy_cache/
27 changes: 27 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

27 changes: 27 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";

outputs =
{ nixpkgs, ... }:
{
/*
This example assumes your system is x86_64-linux
change as neccesary
*/
devShells.x86_64-linux =
let
pkgs = nixpkgs.legacyPackages.x86_64-linux;
lib = pkgs.lib;
in
{
default = pkgs.mkShell {
packages = with pkgs; [ cmake opencv libGL stdenv.cc uv glib ];
LD_LIBRARY_PATH = lib.makeLibraryPath [ pkgs.libGL pkgs.stdenv.cc.cc.lib pkgs.glib ];
shellHook = ''
uv venv
uv sync --frozen
'';
};
};
};
}
15 changes: 15 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[project]
name = "gaze-tracking"
version = "0.1.0"
description = "Add your description here"
readme = "README.md"
requires-python = ">=3.9"
dependencies = [
"dlib>=19.24.4",
"numpy>=1.26.4",
"opencv-python>=4.10.0.82",
]

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
4 changes: 0 additions & 4 deletions requirements.txt

This file was deleted.

188 changes: 188 additions & 0 deletions uv.lock

Large diffs are not rendered by default.