default.nix 782 B

1234567891011121314151617181920212223242526272829303132333435
  1. with import <nixpkgs> {};
  2. stdenv.mkDerivation rec {
  3. name = "deer-${version}";
  4. version = "1.4";
  5. src = fetchFromGitHub {
  6. owner = "Vifon";
  7. repo = "deer";
  8. rev = "v${version}";
  9. sha256 = "1xnbnbi0zk2xsyn8dqsmyxqlfnl36pb1wwibnlp0dxixw6sfymyl";
  10. };
  11. prePatch = ''
  12. substituteInPlace deer --replace \
  13. "| perl -pe " \
  14. "| ${perl}/bin/perl -pe "
  15. '';
  16. patches = [ ./realpath.patch ];
  17. installPhase = ''
  18. mkdir -p $out/share/zsh/site-functions/
  19. cp deer $out/share/zsh/site-functions/
  20. '';
  21. meta = with stdenv.lib; {
  22. description = "Ranger-like file navigation for zsh";
  23. homepage = "https://github.com/Vifon/deer";
  24. license = licenses.gpl3Plus;
  25. maintainers = with maintainers; [ vyp ];
  26. platforms = platforms.unix;
  27. };
  28. }