Skip to content

Commit

Permalink
flake: add devShell
Browse files Browse the repository at this point in the history
  • Loading branch information
figsoda committed Apr 27, 2023
1 parent 23b3606 commit 8865d05
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,21 @@
"x86_64-linux"
]
(system: f nixpkgs.legacyPackages.${system});

runtimeInputs = pkgs:
with pkgs; [
gitMinimal
mercurial
nixVersions.unstable
];
in
{
devShells = eachSystem (pkgs: {
default = pkgs.mkShell {
packages = runtimeInputs pkgs;
};
});

formatter = eachSystem (pkgs: pkgs.nixpkgs-fmt);

herculesCI.ciSystems = [
Expand All @@ -38,11 +51,8 @@
let
inherit (pkgs)
darwin
gitMinimal
installShellFiles
makeBinaryWrapper
mercurial
nixVersions
rustPlatform
stdenv
;
Expand Down Expand Up @@ -83,7 +93,7 @@

postInstall = ''
wrapProgram $out/bin/nurl \
--prefix PATH : ${makeBinPath [ gitMinimal mercurial nixVersions.unstable ]}
--prefix PATH : ${makeBinPath (runtimeInputs pkgs)}
installManPage artifacts/nurl.1
installShellCompletion artifacts/nurl.{bash,fish} --zsh artifacts/_nurl
'';
Expand Down

0 comments on commit 8865d05

Please sign in to comment.