##// END OF EJS Templates
hgk - fix CR issues on windows
"Andrei Vermel " -
r3940:a33ddd20 default
parent child Browse files
Show More
@@ -43,7 +43,9 b' proc getcommits {rargs} {'
43 43 }
44 44 if [catch {
45 45 set parse_args [concat --default HEAD $revargs]
46 set parsed_args [split [eval exec hg debug-rev-parse $parse_args] "\n"]
46 set parse_temp [eval exec hg debug-rev-parse $parse_args]
47 regsub -all "\r\n" $parse_temp "\n" parse_temp
48 set parsed_args [split $parse_temp "\n"]
47 49 } err] {
48 50 # if git-rev-parse failed for some reason...
49 51 if {$rargs == {}} {
@@ -108,6 +110,7 b' to allow selection of commits to be disp'
108 110 set leftover {}
109 111 }
110 112 set start [expr {$i + 1}]
113 regsub -all "\r\n" $cmit "\n" cmit
111 114 set j [string first "\n" $cmit]
112 115 set ok 0
113 116 if {$j >= 0} {
@@ -209,6 +212,7 b' proc parsecommit {id contents listed old'
209 212 incr ncleft($p)
210 213 }
211 214 }
215 regsub -all "\r\n" $contents "\n" contents
212 216 foreach line [split $contents "\n"] {
213 217 if {$inhdr} {
214 218 set line [split $line]
@@ -257,7 +261,8 b' proc readrefs {} {'
257 261 global tagids idtags headids idheads tagcontents
258 262
259 263 set tags [exec hg tags]
260 set lines [split $tags '\n']
264 regsub -all "\r\n" $tags "\n" tags
265 set lines [split $tags "\n"]
261 266 foreach f $lines {
262 267 set f [regexp -all -inline {\S+} $f]
263 268 set direct [lindex $f 0]
@@ -2856,6 +2861,7 b' proc getblobdiffline {bdf ids} {'
2856 2861 if {$ids != $diffids || $bdf != $blobdifffd($ids)} {
2857 2862 return
2858 2863 }
2864 regsub -all "\r" $line "" line
2859 2865 $ctext conf -state normal
2860 2866 if {[regexp {^diff --git a/(.*) b/(.*)} $line match fname newname]} {
2861 2867 # start of a new file
@@ -2914,7 +2920,7 b' proc getblobdiffline {bdf ids} {'
2914 2920 } elseif {$diffinhdr || $x == "\\"} {
2915 2921 # e.g. "\ No newline at end of file"
2916 2922 $ctext insert end "$line\n" filesep
2917 } else {
2923 } elseif {$line != ""} {
2918 2924 # Something else we don't recognize
2919 2925 if {$curdifftag != "Comments"} {
2920 2926 $ctext insert end "\n"
General Comments 0
You need to be logged in to leave comments. Login now