scripts/shell.nix

15 lines
413 B
Nix
Raw Normal View History

{ pkgs ? import <nixpkgs> {} }:
pkgs.mkShell {
nativeBuildInputs = with pkgs; [
gitAndTools.pre-commit
(python3.withPackages(ps: [ ps.virtualenv ]))
];
shellHook = ''
# blacks pre-commit hook builds a wheel (zip file) for black and fails
# when the timestamp is lower than 1980 (due to zip limitations)
export SOURCE_DATE_EPOCH=315532800
pre-commit install -f >/dev/null
'';
}