From b706315dfc326382dbd414e1e34df0fcbd22fd6a Mon Sep 17 00:00:00 2001
From: Sebastian Pipping <sebastian@pipping.org>
Date: Sat, 16 Jan 2021 22:35:51 +0100
Subject: [PATCH] git-big-picture: 0.10.1 -> 1.0.0 (fixes CVE-2021-3028)

Also propagates move of repository from https://github.com/esc/git-big-picture
to https://github.com/git-big-picture/git-big-picture .

Upstream change log at
https://github.com/git-big-picture/git-big-picture#changelog
---
 .../git-and-tools/git-big-picture/default.nix | 20 +++++++++++--------
 1 file changed, 12 insertions(+), 8 deletions(-)

diff --git a/pkgs/applications/version-management/git-and-tools/git-big-picture/default.nix b/pkgs/applications/version-management/git-and-tools/git-big-picture/default.nix
index 6cadd92eb3d1..ec832866c717 100644
--- a/pkgs/applications/version-management/git-and-tools/git-big-picture/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-big-picture/default.nix
@@ -1,19 +1,23 @@
-{ fetchFromGitHub, python2Packages, lib, stdenv, git, graphviz }:
+{ fetchFromGitHub, python3Packages, lib, stdenv, git, graphviz }:
 
-python2Packages.buildPythonApplication rec {
+python3Packages.buildPythonApplication rec {
   pname = "git-big-picture";
-  version = "0.10.1";
+  version = "1.0.0";
 
   src = fetchFromGitHub {
-    owner = "esc";
+    owner = "git-big-picture";
     repo = pname;
     rev = "v${version}";
-    sha256 = "0b0zdq7d7k7f6p3wwc799347fraphbr20rxd1ysnc4xi1cj4wpmi";
+    sha256 = "14yf71iwgk78nw8w0bpijsnnl4vg3bvxsw3vvypxmbrc1nh0bdha";
   };
 
   buildInputs = [ git graphviz ];
 
-  checkInputs = [ git ];
+  # NOTE: Tests are disabled due to unpackaged test dependency "Scruf".
+  #       When bumping to 1.1.0, please re-enable and use:
+  #checkInputs = [ cram git pytest ];
+  #checkPhase = "pytest test.py";
+  doCheck = false;
 
   postFixup = ''
     wrapProgram $out/bin/git-big-picture \
@@ -22,8 +26,8 @@ python2Packages.buildPythonApplication rec {
 
   meta = {
     description = "Tool for visualization of Git repositories";
-    homepage = "https://github.com/esc/git-big-picture";
-    license = lib.licenses.gpl3;
+    homepage = "https://github.com/git-big-picture/git-big-picture";
+    license = lib.licenses.gpl3Plus;
     platforms = lib.platforms.linux;
     maintainers = [ lib.maintainers.nthorne ];
   };