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.1";
+ sha256 = "0ilbhvr0d83kfwkm7ak64gik44gi2axfnp9rzsa7g5cwz9qaxdbv";
+ }
+ }/pinch.py "$@"
+ '';
}