depot/third_party/nixpkgs/pkgs/development/compilers/swift/swiftpm2nix/default.nix
Default email f34ce41345 Project import generated by Copybara.
GitOrigin-RevId: b73c2221a46c13557b1b3be9c2070cc42cf01eb3
2024-07-27 08:49:29 +02:00

26 lines
638 B
Nix

{ lib, stdenv, callPackage, makeWrapper, jq, nix-prefetch-git }:
stdenv.mkDerivation {
name = "swiftpm2nix";
nativeBuildInputs = [ makeWrapper ];
dontUnpack = true;
installPhase = ''
install -vD ${./swiftpm2nix.sh} $out/bin/swiftpm2nix
wrapProgram $out/bin/$name \
--prefix PATH : ${lib.makeBinPath [ jq nix-prefetch-git ]} \
'';
preferLocalBuild = true;
passthru = callPackage ./support.nix { };
meta = {
description = "Generate a Nix expression to fetch swiftpm dependencies";
mainProgram = "swiftpm2nix";
maintainers = lib.teams.swift.members;
platforms = lib.platforms.all;
};
}