changeset 4758:a72dd3bfce41

Merge with crew-stable
author Thomas Arendsen Hein <thomas@intevation.de>
date Sun, 01 Jul 2007 19:19:42 +0200
parents 544a5e3d7d1c (current diff) 4a84f7421692 (diff)
children 20ec5cc02f18
files
diffstat 1 files changed, 16 insertions(+), 15 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/hgk	Sat Jun 30 08:31:23 2007 -0700
+++ b/contrib/hgk	Sun Jul 01 19:19:42 2007 +0200
@@ -43,7 +43,7 @@
     }
     if [catch {
 	set parse_args [concat --default HEAD $revargs]
-	set parse_temp [eval exec {$env(HG)} debug-rev-parse $parse_args]
+	set parse_temp [eval exec {$env(HG)} --config ui.report_untrusted=false debug-rev-parse $parse_args]
 	regsub -all "\r\n" $parse_temp "\n" parse_temp
 	set parsed_args [split $parse_temp "\n"]
     } err] {
@@ -57,7 +57,7 @@
 	set parsed_args [concat -n $limit $parsed_args]
     }
     if [catch {
-	set commfd [open "|{$env(HG)} debug-rev-list --header --topo-order --parents $parsed_args" r]
+	set commfd [open "|{$env(HG)} --config ui.report_untrusted=false debug-rev-list --header --topo-order --parents $parsed_args" r]
     } err] {
 	puts stderr "Error executing hg debug-rev-list: $err"
 	exit 1
@@ -180,7 +180,7 @@
 
 proc readcommit {id} {
     global env
-    if [catch {set contents [exec $env(HG) debug-cat-file commit $id]}] return
+    if [catch {set contents [exec $env(HG) --config ui.report_untrusted=false debug-cat-file commit $id]}] return
     parsecommit $id $contents 0 {}
 }
 
@@ -261,7 +261,7 @@
 proc readrefs {} {
     global tagids idtags headids idheads tagcontents env
 
-    set tags [exec $env(HG) tags]
+    set tags [exec $env(HG) --config ui.report_untrusted=false tags]
     regsub -all "\r\n" $tags "\n" tags
     set lines [split $tags "\n"]
     foreach f $lines {
@@ -1734,8 +1734,7 @@
     }
 
     if {[catch {
-	set f [open [list | $env(HG) debug-diff-tree --stdin -s -r -S$findstring \
-			 << $inputids] r]
+	set f [open [list | $env(HG) --config ui.report_untrusted=false debug-diff-tree --stdin -s -r -S$findstring << $inputids] r]
     } err]} {
 	error_popup "Error starting search process: $err"
 	return
@@ -1838,7 +1837,7 @@
     # start off a git-diff-tree process if needed
     if {$diffsneeded ne {}} {
 	if {[catch {
-	    set df [open [list | $env(HG) debug-diff-tree -r --stdin << $diffsneeded] r]
+	    set df [open [list | $env(HG) --config ui.report_untrusted=false debug-diff-tree -r --stdin << $diffsneeded] r]
 	} err ]} {
 	    error_popup "Error starting search process: $err"
 	    return
@@ -2262,7 +2261,7 @@
 	    set gca $id
 	} else {
 	    if {[catch {
-		set gca [exec $env(HG) debug-merge-base $gca $id]
+		set gca [exec $env(HG) --config ui.report_untrusted=false debug-merge-base $gca $id]
 	    } err]} {
 		return {}
 	    }
@@ -2351,7 +2350,7 @@
     catch {unset grouphunks}
     set groupfilelast -1
     foreach p $parents($diffmergeid) {
-	set cmd [list | $env(HG) debug-diff-tree -p $p $diffmergeid]
+	set cmd [list | $env(HG) --config ui.report_untrusted=false debug-diff-tree -p $p $diffmergeid]
 	set cmd [concat $cmd $mergefilelist($diffmergeid)]
 	if {[catch {set f [open $cmd r]} err]} {
 	    error_popup "Error getting diffs: $err"
@@ -2795,7 +2794,7 @@
     set treediff {}
     set id [lindex $ids 0]
     set p [lindex $ids 1]
-    if [catch {set gdtf [open "|{$env(HG)} debug-diff-tree -r $p $id" r]}] return
+    if [catch {set gdtf [open "|{$env(HG)} --config ui.report_untrusted=false debug-diff-tree -r $p $id" r]}] return
     fconfigure $gdtf -blocking 0
     fileevent $gdtf readable [list gettreediffline $gdtf $ids]
 }
@@ -2820,7 +2819,9 @@
 	}
 	return
     }
-    set file [lindex $line 5]
+    set tab1 [expr [string first "\t" $line] + 1]
+    set tab2 [expr [string first "\t" $line $tab1] - 1]
+    set file [string range $line $tab1 $tab2]
     lappend treediff $file
 }
 
@@ -2831,7 +2832,7 @@
     set id [lindex $ids 0]
     set p [lindex $ids 1]
     set env(GIT_DIFF_OPTS) $diffopts
-    set cmd [list | $env(HG) debug-diff-tree -r -p -C $p $id]
+    set cmd [list | $env(HG) --config ui.report_untrusted=false debug-diff-tree -r -p -C $p $id]
     if {[catch {set bdf [open $cmd r]} err]} {
 	puts "error getting diffs: $err"
 	return
@@ -3419,7 +3420,7 @@
     set oldid [$patchtop.fromsha1 get]
     set newid [$patchtop.tosha1 get]
     set fname [$patchtop.fname get]
-    if {[catch {exec $env(HG) debug-diff-tree -p $oldid $newid >$fname &} err]} {
+    if {[catch {exec $env(HG) --config ui.report_untrusted=false debug-diff-tree -p $oldid $newid >$fname &} err]} {
 	error_popup "Error creating patch: $err"
     }
     catch {destroy $patchtop}
@@ -3478,7 +3479,7 @@
 	return
     }
     if {[catch {
-	set out [exec $env(HG) tag -r $id $tag]
+	set out [exec $env(HG) --config ui.report_untrusted=false tag -r $id $tag]
     } err]} {
 	error_popup "Error creating tag: $err"
 	return
@@ -3640,7 +3641,7 @@
 set datemode 0
 set boldnames 0
 set diffopts "-U 5 -p"
-set wrcomcmd "\"\$HG\" debug-diff-tree --stdin -p --pretty"
+set wrcomcmd "\"\$HG\" --config ui.report_untrusted=false debug-diff-tree --stdin -p --pretty"
 
 set mainfont {Helvetica 9}
 set textfont {Courier 9}