Created
March 10, 2024 07:57
-
-
Save paradx/af5de890145e70b5921e9169aecf1119 to your computer and use it in GitHub Desktop.
default.nix
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ pkgs ? import <nixpkgs> {} }: | |
let | |
poetry2nix = import (pkgs.fetchFromGitHub { | |
owner = "nix-community"; | |
repo = "poetry2nix"; | |
rev = "2024.2.2230616"; # Specify a specific commit hash or tag | |
sha256 = "sha256-3Kq2l6xedw2BkvcASyAzNyjYRvupNiKxUvnBfcqOomM="; # The hash of the source for integrity verification | |
}) { inherit pkgs; }; | |
p2n-overrides = self: super: { | |
ruff = super.ruff.overrideAttrs(oldAttrs: rec{ | |
cargoSha256 = "sha256-U77Bwgbt2T8xkamrWOnOpNRF+8skLWhX8JqgPqowcQw="; | |
}); | |
psycopg2-binary = super.psycopg2-binary.overridePythonAttrs( | |
old: { | |
buildInputs = (old.buildInputs or [ ]) ++ [ self.setuptools self.setuptools-scm]; | |
} | |
); | |
cachetools = super.cachetools.overridePythonAttrs( | |
old: { | |
buildInputs = (old.buildInputs or [ ]) ++ [ self.setuptools self.setuptools-scm]; | |
} | |
); | |
diskcache = super.diskcache.overridePythonAttrs( | |
old: { | |
buildInputs = (old.buildInputs or [ ]) ++ [ self.setuptools self.setuptools-scm]; | |
} | |
); | |
click = super.click.overridePythonAttrs( | |
old: { | |
buildInputs = (old.buildInputs or [ ]) ++ [ self.setuptools self.setuptools-scm]; | |
} | |
); | |
aenum = super.aenum.overridePythonAttrs( | |
old: { | |
buildInputs = (old.buildInputs or [ ]) ++ [ self.setuptools self.setuptools-scm]; | |
} | |
); | |
}; | |
in | |
poetry2nix.mkPoetryApplication { | |
projectDir = ./.; | |
overrides = [ p2n-overrides ]; | |
# preferWheels = true; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment