let # nixpkgs-unstable at 2018-08-20 14:43 nixpkgsRev = "0828e2d8c369604c56219bd7085256b984087280"; defaultNixpkgs = builtins.fetchTarball "github.com/NixOS/nixpkgs/archive/${nixpkgsRev}.tar.gz"; in { nixpkgs ? defaultNixpkgs }: with (import nixpkgs {}); with rustPlatform; buildRustPackage rec { name = "nix-index-${version}"; version = "0.1.2"; src = builtins.filterSource (name: type: !lib.hasPrefix "target" (baseNameOf name) && !lib.hasPrefix "result" (baseNameOf name) && name != ".git") ./.; cargoSha256 = "045qm7cyg3sdvf22i8b9cz8gsvggs5bn9xz8k1pvn5gxb7zj24cx"; buildInputs = [pkgconfig openssl curl]; postInstall = '' mkdir -p $out/etc/profile.d cp ${./command-not-found.sh} $out/etc/profile.d/command-not-found.sh substituteInPlace $out/etc/profile.d/command-not-found.sh \ --replace "@out@" "$out" ''; meta = with stdenv.lib; { description = "A files database for nixpkgs"; homepage = https://github.com/bennofs/nix-index; license = with licenses; [ bsd3 ]; maintainers = [ maintainers.bennofs ]; platforms = platforms.all; }; }