Skip to contentSkip to conversation

show signature of commit in gitk

PATCH In review Daniel Fahlke 2 participants 3 messages Jun 15, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 show signature of commit in gitk

but still depending on the added --show-signature as argument

longer explanation:
git supports for some time now signed commits, and also show the signature and its trust level inside the git log command. Now, it can also get shown in gitk.

---
 gitk-git/gitk | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
gitk-git/gitk +5 -1
index fcc606e..54c167f 100755
@@ -1674,6 +1674,7 @@ proc parsecommit {id contents listed} {
     set audate {}
     set comname {}
     set comdate {}
+    set comgpg {}
     set hdrend [string first "\n\n" $contents]
     if {$hdrend < 0} {
 	# should never happen...
@@ -1690,6 +1691,9 @@ proc parsecommit {id contents listed} {
 	} elseif {$tag == "committer"} {
 	    set comdate [lrange $line end-1 end]
 	    set comname [join [lrange $line 1 end-2] " "]
+	} elseif {$tag == "gpg:"} {
+	    append comgpg [join [lrange $line 1 end] " "]
+	    append comgpg "\n"
 	}
     }
     set headline {}
@@ -1726,7 +1730,7 @@ proc parsecommit {id contents listed} {
 	set comment [string range $comment 0 $i-1]
     }
     set commitinfo($id) [list $headline $auname $audate \
-			     $comname $comdate $comment $hasnote $diff]
+			     $comname $comdate $comment $hasnote $diff $comgpg]
 }
  proc getcommit {id} {
@@ -7325,6 +7329,7 @@ proc selectline {l isnew {desired_loc {}}

{switch_to_patch 0}} {
$ctext insert end "[mc "Author"]: [lindex $info 1] $date\n" set date [formatdate [lindex $info 4]]
$ctext insert end "[mc "Committer"]: [lindex $info 3] $date\n"
+ $ctext insert end [lindex $info 8]

     if {[info exists idtags($id)]} {

$ctext insert end [mc "Tags:"]
foreach tag $idtags($id) {

Signature · 1 line
2.6.3
#1 lore raw

It seems my Patch got no attention yet, is there anything wrong? Do I need to ping someone in particular?

Quoted 52 lines · Daniel Fahlke

but still depending on the added --show-signature as argument

longer explanation:
git supports for some time now signed commits, and also show the signature and its trust level inside the git log command. Now, it can also get shown in gitk.

---
 gitk-git/gitk | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
gitk-git/gitk +6 -1
index fcc606e..54c167f 100755
@@ -1674,6 +1674,7 @@ proc parsecommit {id contents listed} {
     set audate {}
     set comname {}
     set comdate {}
+    set comgpg {}
     set hdrend [string first "\n\n" $contents]
     if {$hdrend < 0} {
 	# should never happen...
@@ -1690,6 +1691,9 @@ proc parsecommit {id contents listed} {
 	} elseif {$tag == "committer"} {
 	    set comdate [lrange $line end-1 end]
 	    set comname [join [lrange $line 1 end-2] " "]
+	} elseif {$tag == "gpg:"} {
+	    append comgpg [join [lrange $line 1 end] " "]
+	    append comgpg "\n"
 	}
     }
     set headline {}
@@ -1726,7 +1730,7 @@ proc parsecommit {id contents listed} {
 	set comment [string range $comment 0 $i-1]
     }
     set commitinfo($id) [list $headline $auname $audate \
-			     $comname $comdate $comment $hasnote $diff]
+			     $comname $comdate $comment $hasnote $diff $comgpg]
 }
  proc getcommit {id} {
@@ -7325,6 +7329,7 @@ proc selectline {l isnew {desired_loc {}}
 {switch_to_patch 0}} {
     $ctext insert end "[mc "Author"]: [lindex $info 1]  $date\n"
     set date [formatdate [lindex $info 4]]
     $ctext insert end "[mc "Committer"]: [lindex $info 3]  $date\n"
+    $ctext insert end [lindex $info 8]
     if {[info exists idtags($id)]} {
 	$ctext insert end [mc "Tags:"]

foreach tag $idtags($id) {

#2 lore raw
Quoted 3 lines · Daniel Fahlke

It seems my Patch got no attention yet, is there anything wrong? Do I need to ping someone in particular?

gitk patches should cc +Paul Mackerras <[email protected]> who maintains gitk