]> git.scottworley.com Git - auto-upgrade-with-pinch/blobdiff - overlays/pinch.nix
pinch: 1.1 -> 1.2
[auto-upgrade-with-pinch] / overlays / pinch.nix
index 1b2c65f66545284feb21af06df8e1c44e9e17834..ddaed6f9389bab33747fbff9731ab2e579d0cb6b 100644 (file)
@@ -1,9 +1,14 @@
 self: super: {
-  pinch = super.writeShellScriptBin "pinch" ''
-    exec ${self.python3}/bin/python3 ${super.fetchgit {
-      url = "https://scottworley.com/pinch.git";
-      rev = "1.1";
-      sha256 = "0ilbhvr0d83kfwkm7ak64gik44gi2axfnp9rzsa7g5cwz9qaxdbv";
-    }}/pinch.py "$@"
-  '';
+  pinch = if builtins.hasAttr "pinch" super then
+    super.pinch
+  else
+    super.writeShellScriptBin "pinch" ''
+      exec ${self.python3}/bin/python3 ${
+        super.fetchgit {
+          url = "https://scottworley.com/pinch.git";
+          rev = "1.2";
+          sha256 = "0s0rk1m0irsdj0xjnix9y1825pjv7lhbmnn73jgjbj1hi6wqwpfh";
+        }
+      }/pinch.py "$@"
+    '';
 }