Files
dibbler/nix/package.nix
h7x4 4ed68ff05c nix: yeet skrott, massive module modifications tm, wrap package and more
Sorry for the kinda big commit that does everything at once

This change does the following:
- yeets skrott and skrot-specific settings from the NixOS module,
- adds a bunch more settings and generalizations to the NixOS module,
- adds two VM NixOS configurations for interactive testing
- wraps the nix package so that `less` is always present in `$PATH`
- yeah, that's about it

kthxbye
2026-01-06 17:01:21 +09:00

42 lines
835 B
Nix

{ lib
, python3Packages
, makeWrapper
, less
}:
let
pyproject = builtins.fromTOML (builtins.readFile ../pyproject.toml);
in
python3Packages.buildPythonApplication {
pname = pyproject.project.name;
version = pyproject.project.version;
src = lib.cleanSource ../.;
format = "pyproject";
# brother-ql is breaky breaky
# https://github.com/NixOS/nixpkgs/issues/285234
dontCheckRuntimeDeps = true;
nativeBuildInputs = with python3Packages; [
setuptools
makeWrapper
];
propagatedBuildInputs = with python3Packages; [
brother-ql
matplotlib
psycopg2
python-barcode
sqlalchemy
];
postInstall = ''
wrapProgram $out/bin/dibbler \
--prefix PATH : "${lib.makeBinPath [ less ]}"
'';
meta = {
description = "The little kiosk that could";
mainProgram = "dibbler";
};
}