nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix

python310Packages.poetry-dynamic-versioning: Add setup-hook

to not so dynamically set the package version.

authored by

Martin Weinelt and committed by
Martin Weinelt
f71d4911 35e5b06a

+10
+2
pkgs/development/python-modules/poetry-dynamic-versioning/default.nix
··· 56 56 "poetry_dynamic_versioning" 57 57 ]; 58 58 59 + setupHook = ./setup-hook.sh; 60 + 59 61 meta = with lib; { 60 62 description = "Plugin for Poetry to enable dynamic versioning based on VCS tags"; 61 63 homepage = "https://github.com/mtkennerly/poetry-dynamic-versioning";
+8
pkgs/development/python-modules/poetry-dynamic-versioning/setup-hook.sh
··· 1 + version-pretend-hook() { 2 + echo "Setting POETRY_DYNAMIC_VERSIONING_BYPASS to $version" 3 + export POETRY_DYNAMIC_VERSIONING_BYPASS=$version 4 + } 5 + 6 + if [ -z "${dontBypassPoetryDynamicVersioning-}" ]; then 7 + preBuildHooks+=(version-pretend-hook) 8 + fi