forked from NixOS/nixpkgs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
nix-universal-prefetch: init at 0.4.0
This package was deleted in 578d7e7. This broke the Electron update script. This fixes the Electron update script. Fixes NixOS#321490
- Loading branch information
Showing
2 changed files
with
34 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
{ lib, stdenv | ||
, fetchFromGitHub | ||
, ruby | ||
}: | ||
|
||
# No gems used, so mkDerivation is fine. | ||
stdenv.mkDerivation rec { | ||
pname = "nix-universal-prefetch"; | ||
version = "0.4.0"; | ||
|
||
src = fetchFromGitHub { | ||
owner = "Marcus-Arcadius"; | ||
repo = "nix-universal-prefetch"; | ||
rev = "v${version}"; | ||
hash = "sha256-HGn4qHWqpUwlS3yQrD3j5oH0yOlphsoSPD2vkyyRv+0="; | ||
}; | ||
|
||
installPhase = '' | ||
mkdir -pv $out/bin | ||
cp nix-universal-prefetch $out/bin/nix-universal-prefetch | ||
substituteInPlace "$out/bin/nix-universal-prefetch" \ | ||
--replace "/usr/bin/env nix-shell" "${ruby}/bin/ruby" | ||
''; | ||
|
||
meta = with lib; { | ||
description = "Uses nixpkgs fetchers to figure out hashes"; | ||
homepage = "https://github.com/squalus/nix-universal-prefetch"; | ||
license = licenses.mit; | ||
maintainers = with maintainers; [ squalus ]; | ||
platforms = platforms.linux ++ platforms.darwin; | ||
mainProgram = "nix-universal-prefetch"; | ||
}; | ||
} | ||
|
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