summary refs log tree commit diff
path: root/pkgs/tools/misc/ponysay/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/tools/misc/ponysay/default.nix')
-rw-r--r--pkgs/tools/misc/ponysay/default.nix27
1 files changed, 14 insertions, 13 deletions
diff --git a/pkgs/tools/misc/ponysay/default.nix b/pkgs/tools/misc/ponysay/default.nix
index 113c2b05ff5..b27aa32481c 100644
--- a/pkgs/tools/misc/ponysay/default.nix
+++ b/pkgs/tools/misc/ponysay/default.nix
@@ -1,20 +1,21 @@
-{ lib, stdenv, fetchurl, python3, texinfo, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, python3, texinfo, makeWrapper }:
 
-stdenv.mkDerivation {
-  name = "ponysay-3.0.3";
+stdenv.mkDerivation rec {
+  name = "ponysay";
+  version = "3.0.3";
 
-  src = fetchurl {
-    url = "https://github.com/erkin/ponysay/archive/3.0.3.tar.gz";
-    sha256 = "12mjabf5cpp5dgg63s19rlyq3dhhpzzy2sa439yncqzsk7rdg0n3";
+  src = fetchFromGitHub {
+    owner = "erkin";
+    repo = "ponysay";
+    rev = version;
+    sha256 = "sha256-R2B0TU3ZSEncGsijKgvhaHIbcZa5Dx/jVPxrILBaoVw=";
   };
 
   nativeBuildInputs = [ makeWrapper ];
-  buildInputs = [ python3 texinfo  ];
+  buildInputs = [ python3 texinfo ];
 
   inherit python3;
 
-  phases = "unpackPhase installPhase fixupPhase";
-
   installPhase = ''
     find -type f -name "*.py" | xargs sed -i "s@/usr/bin/env python3@$python3/bin/python3@g"
     substituteInPlace setup.py --replace \
@@ -25,11 +26,11 @@ stdenv.mkDerivation {
         --with-bash
   '';
 
-  meta = {
+  meta = with lib; {
     description = "Cowsay reimplemention for ponies";
     homepage = "https://github.com/erkin/ponysay";
-    license = lib.licenses.gpl3;
-    maintainers = with lib.maintainers; [ bodil ];
-    platforms = with lib.platforms; unix;
+    license = licenses.gpl3;
+    maintainers = with maintainers; [ bodil ];
+    platforms = platforms.unix;
   };
 }