Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at fix-function-merge 51 lines 1.1 kB view raw
1{ lib 2, stdenv 3, fetchFromGitHub 4, installShellFiles 5}: 6 7stdenv.mkDerivation rec { 8 pname = "pyenv"; 9 version = "2.4.8"; 10 11 src = fetchFromGitHub { 12 owner = "pyenv"; 13 repo = "pyenv"; 14 rev = "refs/tags/v${version}"; 15 hash = "sha256-JXNEAgppFbeNKxjvrI/jUyHmN6pSWUFGSrxeVZi5pHw="; 16 }; 17 18 nativeBuildInputs = [ 19 installShellFiles 20 ]; 21 22 configureScript = "src/configure"; 23 24 makeFlags = ["-C" "src"]; 25 26 installPhase = '' 27 runHook preInstall 28 29 mkdir -p "$out" 30 cp -R bin "$out/bin" 31 cp -R libexec "$out/libexec" 32 cp -R plugins "$out/plugins" 33 34 runHook postInstall 35 ''; 36 37 postInstall = '' 38 installManPage man/man1/pyenv.1 39 installShellCompletion completions/pyenv.{bash,fish,zsh} 40 ''; 41 42 meta = with lib; { 43 description = "Simple Python version management"; 44 homepage = "https://github.com/pyenv/pyenv"; 45 changelog = "https://github.com/pyenv/pyenv/blob/${src.rev}/CHANGELOG.md"; 46 license = licenses.mit; 47 maintainers = with maintainers; [ tjni ]; 48 platforms = platforms.all; 49 mainProgram = "pyenv"; 50 }; 51}