Skip to content

Commit fc4b10c

Browse files
committed
Merge git://git.kernel.org/pub/scm/gitk/gitk
* git://git.kernel.org/pub/scm/gitk/gitk: gitk: Update German translation gitk: Add French translation gitk: update Italian translation gitk: Update Swedish translation gitk: Adjust two equal strings which differed in whitespace gitk: Display submodule diffs with appropriate encoding gitk: Fix display of newly-created tags gitk: Enable gitk to create tags with messages gitk: Update Hungarian translation gitk: Add Hungarian translation gitk: Add "--no-replace-objects" option
2 parents 02e5124 + d70bb62 commit fc4b10c

File tree

6 files changed

+3989
-889
lines changed

6 files changed

+3989
-889
lines changed

gitk-git/gitk

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ proc unmerged_files {files} {
130130
}
131131

132132
proc parseviewargs {n arglist} {
133-
global vdatemode vmergeonly vflags vdflags vrevs vfiltered vorigargs
133+
global vdatemode vmergeonly vflags vdflags vrevs vfiltered vorigargs env
134134

135135
set vdatemode($n) 0
136136
set vmergeonly($n) 0
@@ -210,6 +210,9 @@ proc parseviewargs {n arglist} {
210210
# git rev-parse doesn't understand --merge
211211
lappend revargs --gitk-symmetric-diff-marker MERGE_HEAD...HEAD
212212
}
213+
"--no-replace-objects" {
214+
set env(GIT_NO_REPLACE_OBJECTS) "1"
215+
}
213216
"-*" {
214217
# Other flag arguments including -<n>
215218
if {[string is digit -strict [string range $arg 1 end]]} {
@@ -2085,7 +2088,7 @@ proc makewindow {} {
20852088
set sha1entry .tf.bar.sha1
20862089
set entries $sha1entry
20872090
set sha1but .tf.bar.sha1label
2088-
button $sha1but -text [mc "SHA1 ID: "] -state disabled -relief flat \
2091+
button $sha1but -text "[mc "SHA1 ID:"] " -state disabled -relief flat \
20892092
-command gotocommit -width 8
20902093
$sha1but conf -disabledforeground [$sha1but cget -foreground]
20912094
pack .tf.bar.sha1label -side left
@@ -7686,8 +7689,10 @@ proc getblobdiffline {bdf ids} {
76867689
makediffhdr $fname $ids
76877690
$ctext insert end "\n$line\n" filesep
76887691
} elseif {![string compare -length 3 " >" $line]} {
7692+
set line [encoding convertfrom $diffencoding $line]
76897693
$ctext insert end "$line\n" dresult
76907694
} elseif {![string compare -length 3 " <" $line]} {
7695+
set line [encoding convertfrom $diffencoding $line]
76917696
$ctext insert end "$line\n" d0
76927697
} elseif {$diffinhdr} {
76937698
if {![string compare -length 12 "rename from " $line]} {
@@ -8698,6 +8703,11 @@ proc mktag {} {
86988703
${NS}::label $top.tlab -text [mc "Tag name:"]
86998704
${NS}::entry $top.tag -width 60
87008705
grid $top.tlab $top.tag -sticky w
8706+
${NS}::label $top.op -text [mc "Tag message is optional"]
8707+
grid $top.op -columnspan 2 -sticky we
8708+
${NS}::label $top.mlab -text [mc "Tag message:"]
8709+
${NS}::entry $top.msg -width 60
8710+
grid $top.mlab $top.msg -sticky w
87018711
${NS}::frame $top.buts
87028712
${NS}::button $top.buts.gen -text [mc "Create"] -command mktaggo
87038713
${NS}::button $top.buts.can -text [mc "Cancel"] -command mktagcan
@@ -8715,6 +8725,7 @@ proc domktag {} {
87158725

87168726
set id [$mktagtop.sha1 get]
87178727
set tag [$mktagtop.tag get]
8728+
set msg [$mktagtop.msg get]
87188729
if {$tag == {}} {
87198730
error_popup [mc "No tag name specified"] $mktagtop
87208731
return 0
@@ -8724,7 +8735,11 @@ proc domktag {} {
87248735
return 0
87258736
}
87268737
if {[catch {
8727-
exec git tag $tag $id
8738+
if {$msg != {}} {
8739+
exec git tag -a -m $msg $tag $id
8740+
} else {
8741+
exec git tag $tag $id
8742+
}
87288743
} err]} {
87298744
error_popup "[mc "Error creating tag:"] $err" $mktagtop
87308745
return 0
@@ -10480,7 +10495,7 @@ proc showtag {tag isnew} {
1048010495
set linknum 0
1048110496
if {![info exists tagcontents($tag)]} {
1048210497
catch {
10483-
set tagcontents($tag) [exec git cat-file tag $tagobjid($tag)]
10498+
set tagcontents($tag) [exec git cat-file tag $tag]
1048410499
}
1048510500
}
1048610501
if {[info exists tagcontents($tag)]} {

0 commit comments

Comments
 (0)