<pre style='margin:0'>
Joshua Root (jmroot) pushed a commit to branch master
in repository macports-base.
</pre>
<p><a href="https://github.com/macports/macports-base/commit/f793ad8d595fcdaec621d95704568d27fd77f366">https://github.com/macports/macports-base/commit/f793ad8d595fcdaec621d95704568d27fd77f366</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new f793ad8 Use eq and ne for string comparisons
</span>f793ad8 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit f793ad8d595fcdaec621d95704568d27fd77f366
</span>Author: Joshua Root <jmr@macports.org>
AuthorDate: Wed Dec 28 19:34:00 2016 +1100
<span style='display:block; white-space:pre;color:#404040;'> Use eq and ne for string comparisons
</span>---
src/macports1.0/macports_util.tcl | 2 +-
src/package1.0/portarchivefetch.tcl | 12 ++++-----
src/package1.0/portdmg.tcl | 2 +-
src/package1.0/portmdmg.tcl | 2 +-
src/package1.0/portmpkg.tcl | 2 +-
src/package1.0/portunarchive.tcl | 4 +--
src/port/port.tcl | 32 ++++++++++++------------
src/port1.0/fetch_common.tcl | 6 ++---
src/port1.0/portchecksum.tcl | 2 +-
src/port1.0/portclean.tcl | 4 +--
src/port1.0/portdestroot.tcl | 8 +++---
src/port1.0/portdistcheck.tcl | 10 ++++----
src/port1.0/portextract.tcl | 2 +-
src/port1.0/portfetch.tcl | 10 ++++----
src/port1.0/portlint.tcl | 16 ++++++------
src/port1.0/portstartupitem.tcl | 6 ++---
src/port1.0/portutil.tcl | 50 ++++++++++++++++++-------------------
src/registry2.0/portimage.tcl | 14 +++++------
src/registry2.0/receipt_sqlite.tcl | 2 +-
src/registry2.0/registry.tcl | 6 ++---
20 files changed, 96 insertions(+), 96 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/macports1.0/macports_util.tcl b/src/macports1.0/macports_util.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 3d51b89..441e505 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/macports1.0/macports_util.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/macports1.0/macports_util.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -187,7 +187,7 @@ proc lunshift {varName args} {
</span> # bytesize filesize ?unit? ?format?
# Format an integer representing bytes using given units
proc bytesize {siz {unit {}} {format {%.2f}}} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$unit == {}} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$unit eq {}} {
</span> if {$siz > 0x40000000} {
set unit "GiB"
} elseif {$siz > 0x100000} {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/package1.0/portarchivefetch.tcl b/src/package1.0/portarchivefetch.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 7f3a8e7..e9f0918 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/package1.0/portarchivefetch.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/package1.0/portarchivefetch.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -93,9 +93,9 @@ proc portarchivefetch::filter_sites {} {
</span> continue
}
if {$portfetch::mirror_sites::sites($site) ne {} &&
<span style='display:block; white-space:pre;background:#ffe0e0;'>- $portfetch::mirror_sites::archive_prefix($site) == $prefix &&
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- $portfetch::mirror_sites::archive_frameworks_dir($site) == $frameworks_dir &&
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- $portfetch::mirror_sites::archive_applications_dir($site) == $applications_dir &&
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $portfetch::mirror_sites::archive_prefix($site) eq $prefix &&
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $portfetch::mirror_sites::archive_frameworks_dir($site) eq $frameworks_dir &&
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $portfetch::mirror_sites::archive_applications_dir($site) eq $applications_dir &&
</span> ![catch {archiveTypeIsSupported $portfetch::mirror_sites::archive_type($site)}]} {
# using the archive type as a tag
lappend ret ${site}::$portfetch::mirror_sites::archive_type($site)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -172,7 +172,7 @@ proc portarchivefetch::fetchfiles {args} {
</span> }
set incoming_path [file join [option portdbpath] incoming]
chownAsRoot $incoming_path
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[info exists elevated] && $elevated == yes} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[info exists elevated] && $elevated eq "yes"} {
</span> dropPrivileges
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -181,10 +181,10 @@ proc portarchivefetch::fetchfiles {args} {
</span> lappend fetch_options -u
lappend fetch_options "${archivefetch.user}:${archivefetch.password}"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${archivefetch.use_epsv} != "yes"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${archivefetch.use_epsv} ne "yes"} {
</span> lappend fetch_options "--disable-epsv"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${archivefetch.ignore_sslcert} != "no"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${archivefetch.ignore_sslcert} ne "no"} {
</span> lappend fetch_options "--ignore-ssl-cert"
}
if {$portverbose eq "yes"} {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/package1.0/portdmg.tcl b/src/package1.0/portdmg.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index b1559f5..035d544 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/package1.0/portdmg.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/package1.0/portdmg.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -75,7 +75,7 @@ proc portdmg::package_dmg {portname portversion portrevision} {
</span> }
# partition for .dmg
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${os.major} >= 9 && ${os.arch} == "i386"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} >= 9 && ${os.arch} eq "i386"} {
</span> # GUID_partition_scheme
set subdev 1
} else {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/package1.0/portmdmg.tcl b/src/package1.0/portmdmg.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 0ff88be..7bc4870 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/package1.0/portmdmg.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/package1.0/portmdmg.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -75,7 +75,7 @@ proc portmdmg::package_mdmg {portname portepoch portversion portrevision} {
</span> }
# partition for .dmg
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${os.major} >= 9 && ${os.arch} == "i386"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} >= 9 && ${os.arch} eq "i386"} {
</span> # GUID_partition_scheme
set subdev 1
} else {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/package1.0/portmpkg.tcl b/src/package1.0/portmpkg.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 4d1b266..af8e46c 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/package1.0/portmpkg.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/package1.0/portmpkg.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -181,7 +181,7 @@ proc portmpkg::package_mpkg {portname portepoch portversion portrevision} {
</span> }
set mport [lindex $dep 4]
# don't re-package ourself
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$name != $portname} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$name ne $portname} {
</span> make_one_package $name $mport
if {${package.flat} && ${os.major} >= 10} {
lappend dependencies org.macports.${name} ${name}-${epoch_namestr}${vers}${rev_namestr}-component.pkg
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/package1.0/portunarchive.tcl b/src/package1.0/portunarchive.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index efc573f..a865056 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/package1.0/portunarchive.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/package1.0/portunarchive.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -84,7 +84,7 @@ proc portunarchive::unarchive_init {args} {
</span> set unarchive.path [find_portarchive_path]
set unarchive.file [file tail ${unarchive.path}]
set unarchive.type [string range [file extension ${unarchive.file}] 1 end]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${unarchive.path} != ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${unarchive.path} ne ""} {
</span> ui_debug "Found [string toupper ${unarchive.type}] archive: ${unarchive.path}"
} else {
if {[info exists ports_binary_only] && $ports_binary_only eq "yes"} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -259,7 +259,7 @@ proc portunarchive::unarchive_main {args} {
</span>
# Unpack the archive
ui_info "$UI_PREFIX [format [msgcat::mc "Extracting %s"] ${unarchive.file}]"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${unarchive.pipe_cmd} == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${unarchive.pipe_cmd} eq ""} {
</span> command_exec unarchive
} else {
command_exec unarchive "${unarchive.pipe_cmd} (" ")"
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port/port.tcl b/src/port/port.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index c1e1f00..f0c18bc 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port/port.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port/port.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -370,7 +370,7 @@ proc require_portlist { nameportlist {is_upgrade "no"} } {
</span> upvar $nameportlist portlist
if {[llength $portlist] == 0 && (![info exists private_options(ports_no_args)] || $private_options(ports_no_args) eq "no")} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${is_upgrade} == "yes"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${is_upgrade} eq "yes"} {
</span> # $> port upgrade outdated
# Error: No ports matched the given expression
# is not very user friendly - if we're in the special case of
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -720,7 +720,7 @@ proc get_installed_ports { {ignore_active yes} {active yes} } {
</span> set ivariants [split_variants [lindex $i 3]]
set iactive [lindex $i 4]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { ${ignore_active} == "yes" || (${active} == "yes") == (${iactive} != 0) } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${ignore_active} eq "yes" || (${active} eq "yes") == (${iactive} != 0) } {
</span> add_to_portlist results [list name $iname version "${iversion}_${irevision}" variants $ivariants]
}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -904,7 +904,7 @@ proc get_ports_with_prop {propname propval} {
</span> set ivariants [lindex $i 3]
set iepoch [lindex $i 5]
set regref [registry::open_entry $iname $iversion $irevision $ivariants $iepoch]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[registry::property_retrieve $regref $propname] == $propval} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[registry::property_retrieve $regref $propname] eq $propval} {
</span> add_to_portlist results [list name $iname version "${iversion}_${irevision}" variants [split_variants $ivariants]]
}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1533,7 +1533,7 @@ proc opIntersection { a b } {
</span> # Quote the fullname and portname to avoid special characters messing up the regexp
set safefullname [regex_pat_sanitize $port(fullname)]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set simpleform [expr { "$port(name)/" == $port(fullname) }]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set simpleform [expr { "$port(name)/" eq $port(fullname) }]
</span> if {$simpleform} {
set pat "^${safefullname}"
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1577,7 +1577,7 @@ proc opComplement { a b } {
</span> # Quote the fullname and portname to avoid special characters messing up the regexp
set safefullname [regex_pat_sanitize $port(fullname)]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set simpleform [expr { "$port(name)/" == $port(fullname) }]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set simpleform [expr { "$port(name)/" eq $port(fullname) }]
</span> if {$simpleform} {
set pat "^${safefullname}"
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2533,7 +2533,7 @@ proc action_deactivate { action portlist opts } {
</span> set iversion [lindex $i 1]
set irevision [lindex $i 2]
set ivariants [lindex $i 3]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$composite_version eq "" || $composite_version == "${iversion}_${irevision}${ivariants}"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$composite_version eq "" || $composite_version eq "${iversion}_${irevision}${ivariants}"} {
</span> set regref [registry::entry open $portname $iversion $irevision $ivariants [lindex $i 5]]
if {[$regref installtype] eq "image" && [registry::run_target $regref deactivate [array get options]]} {
continue
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2618,7 +2618,7 @@ proc action_select { action portlist opts } {
</span> ui_notice "Available versions for $group:"
foreach v $versions {
ui_notice -nonewline "\t"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$selected_version == $v} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$selected_version eq $v} {
</span> ui_msg "$v (active)"
} else {
ui_msg "$v"
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -4231,8 +4231,8 @@ proc advance {} {
</span> }
<span style='display:block; white-space:pre;background:#ffe0e0;'>-proc match s {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[lookahead] == $s} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+proc match {s} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[lookahead] eq $s} {
</span> advance
return 1
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -4472,7 +4472,7 @@ proc cmd_option_matches {action option} {
</span> set argc [lindex $item 1]
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$name == $option} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$name eq $option} {
</span> set result [list [list $name $argc]]
break
} elseif {[string first $option $name] == 0} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -4656,12 +4656,12 @@ proc process_cmd { argv } {
</span> advance
# Handle command separator
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { $action == ";" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { $action eq ";" } {
</span> continue
}
# Handle a comment
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { [string index $action 0] == "#" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { [string index $action 0] eq "#" } {
</span> while { [moreargs] } { advance }
break
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5419,7 +5419,7 @@ namespace eval portclient::questions {
</span> # Custom question message. Defaults to "Continue?".
proc ui_ask_yesno {msg name ports def {timeout 0} {question "Continue?"}} {
# Set number default to the given letter default
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$def == {y}} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$def eq "y"} {
</span> set default 0
} else {
set default 1
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5449,7 +5449,7 @@ namespace eval portclient::questions {
</span> }
# Check for the default and print accordingly
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$def == {y}} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$def eq "y"} {
</span> puts -nonewline "${question} \[Y/n\]: "
flush stdout
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5473,7 +5473,7 @@ namespace eval portclient::questions {
</span> return 0
} elseif {$input in {n N}} {
return 1
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {$input == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {$input eq ""} {
</span> return $default
} else {
puts "Please enter either 'y' or 'n'."
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5550,7 +5550,7 @@ namespace eval portclient::questions {
</span> }
signal -restart error {TERM INT}
# check if input is non-empty and otherwise fine
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$input == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$input eq ""} {
</span> return []
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/fetch_common.tcl b/src/port1.0/fetch_common.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 352d1e5..af2371b 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/fetch_common.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/fetch_common.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -90,7 +90,7 @@ proc portfetch::mirror_sites {mirrors tag subdir mirrorfile} {
</span> }
if {![info exists portfetch::mirror_sites::sites($mirrors)]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$mirrors != $global_mirror_site} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$mirrors ne $global_mirror_site} {
</span> ui_warn "[format [msgcat::mc "No mirror sites on file for class %s"] $mirrors]"
}
return {}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -218,7 +218,7 @@ proc portfetch::sortsites {urls default_listvar} {
</span>
foreach {url_var distfile} $fetch_urls {
if {![info exists urlmap($url_var)]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$url_var != $default_listvar} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$url_var ne $default_listvar} {
</span> ui_error [format [msgcat::mc "No defined site for tag: %s, using $default_listvar"] $url_var]
set urlmap($url_var) $urlmap($default_listvar)
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -255,7 +255,7 @@ proc portfetch::sortsites {urls default_listvar} {
</span> if { ![info exists seen($host)] } {
# first check the persistent cache
set pingtimes($host) [get_pingtime $host]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$pingtimes($host) == {}} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$pingtimes($host) eq {}} {
</span> if {[catch {set fds($host) [open "|ping -noq -c3 -t3 $host | grep round-trip | cut -d / -f 5"]}]} {
ui_debug "Spawning ping for $host failed"
# will end up after all hosts that were pinged OK but before those that didn't respond
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portchecksum.tcl b/src/port1.0/portchecksum.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 6454afa..327dace 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portchecksum.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portchecksum.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -281,7 +281,7 @@ proc portchecksum::checksum_main {args} {
</span>
if {[tbool fail] && ![regexp {\.html?$} ${distfile}] &&
![catch {strsed [exec [findBinary file $portutil::autoconf::file_path] $fullpath --brief --mime] {s/;.*$//}} mimetype]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- && "text/html" == $mimetype} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ && "text/html" eq $mimetype} {
</span> # file --mime-type would be preferable to file --mime and strsed, but is only available as of Snow Leopard
set wrong_mimetype yes
set htmlfile_path ${fullpath}.html
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portclean.tcl b/src/port1.0/portclean.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 82cf273..03300bb 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portclean.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portclean.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -141,7 +141,7 @@ proc portclean::clean_dist {args} {
</span> # next remove dist_subdir if only needed for this port,
# or if user forces us to
set dirlist [list]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$dist_subdir != $name} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$dist_subdir ne $name} {
</span> if {!([info exists ports_force] && $ports_force eq "yes")
&& [file isdirectory $distpath]
&& [llength [readdir $distpath]] > 0} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -242,7 +242,7 @@ proc portclean::clean_archive {args} {
</span> # thus can't be checked and aren't useful anyway.
set archivetype [string range [file extension $path] 1 end]
if {[file isfile $path] && ($archivetype eq "TMP"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- || [extract_archive_metadata $path $archivetype portname] == $subport)} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ || [extract_archive_metadata $path $archivetype portname] eq $subport)} {
</span> ui_debug "Removing archive: $path"
if {[catch {delete $path} result]} {
ui_debug "$::errorInfo"
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portdestroot.tcl b/src/port1.0/portdestroot.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index e18cbaf..c2459b7 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portdestroot.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portdestroot.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -130,12 +130,12 @@ proc portdestroot::destroot_start {args} {
</span> set oldmask [umask ${destroot.umask}]
set mtree [findBinary mtree ${portutil::autoconf::mtree_path}]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { ${destroot.clean} == "yes" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${destroot.clean} eq "yes" } {
</span> delete "${destroot}"
}
file mkdir "${destroot}"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { ${os.platform} == "darwin" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${os.platform} eq "darwin" } {
</span> system "cd \"${destroot}\" && ${mtree} -e -U -f [file join ${portsharepath} install macosx.mtree]"
file mkdir "${destroot}${applications_dir}"
file mkdir "${destroot}${frameworks_dir}"
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -315,7 +315,7 @@ proc portdestroot::destroot_finish {args} {
</span> }
# test for violations of mtree
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { ${destroot.violate_mtree} != "yes" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${destroot.violate_mtree} ne "yes" } {
</span> ui_debug "checking for mtree violations"
set mtree_violation "no"
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -378,7 +378,7 @@ proc portdestroot::destroot_finish {args} {
</span> }
# abort here only so all violations can be observed
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { ${mtree_violation} != "no" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${mtree_violation} ne "no" } {
</span> ui_warn "[format [msgcat::mc "%s violates the layout of the ports-filesystems!"] [option subport]]"
ui_warn "Please fix or indicate this misbehavior (if it is intended), it will be an error in future releases!"
# error "mtree violation!"
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portdistcheck.tcl b/src/port1.0/portdistcheck.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 007b425..7f9119f 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portdistcheck.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portdistcheck.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -64,8 +64,8 @@ proc portdistcheck::distcheck_main {args} {
</span> }
# Check the distfiles if it's a regular fetch phase.
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {"${distcheck.type}" != "none"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- && "${fetch.type}" == "standard"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {"${distcheck.type}" ne "none"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ && "${fetch.type}" eq "standard"} {
</span> # portfetch 1.0::checkfiles sets fetch_urls list.
set fetch_urls {}
portfetch::checkfiles fetch_urls
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -78,7 +78,7 @@ proc portdistcheck::distcheck_main {args} {
</span> ui_error [format [msgcat::mc "No defined site for tag: %s, using master_sites"] $url_var]
set urlmap($url_var) $master_sites
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${distcheck.type} == "moddate"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${distcheck.type} eq "moddate"} {
</span> set count 0
foreach site $urlmap($url_var) {
ui_debug [format [msgcat::mc "Checking %s from %s"] $distfile $site]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -96,7 +96,7 @@ proc portdistcheck::distcheck_main {args} {
</span> if {$count == 0} {
ui_error "no mirror had $distfile for $subport"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {${distcheck.type} == "filesize"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {${distcheck.type} eq "filesize"} {
</span> set count 0
foreach site $urlmap($url_var) {
ui_debug [format [msgcat::mc "Checking %s from %s"] $distfile $site]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -122,7 +122,7 @@ proc portdistcheck::distcheck_main {args} {
</span> }
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${distcheck.type} == "filesize" && $totalsize > 0} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${distcheck.type} eq "filesize" && $totalsize > 0} {
</span> if {$totalsize < 1024} {
set size $totalsize
set humansize "${size}"
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portextract.tcl b/src/port1.0/portextract.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index f90fb54..d0aac51 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portextract.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portextract.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -64,7 +64,7 @@ set_ui_prefix
</span> # Helper function for portextract.tcl that strips all tag names from a list
# Used to clean ${distfiles} for setting the ${extract.only} default
proc portextract::disttagclean {list} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {"$list" == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$list eq ""} {
</span> return $list
}
foreach name $list {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portfetch.tcl b/src/port1.0/portfetch.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 4a692f9..665f6a3 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portfetch.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portfetch.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -333,7 +333,7 @@ proc portfetch::cvsfetch {args} {
</span> patch_sites patchfiles filespath
set cvs.args "${cvs.method} ${cvs.args}"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${cvs.method} == "export" && ![string length ${cvs.tag}] && ![string length ${cvs.date}]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${cvs.method} eq "export" && ![string length ${cvs.tag}] && ![string length ${cvs.date}]} {
</span> set cvs.tag "HEAD"
}
if {[string length ${cvs.tag}]} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -492,13 +492,13 @@ proc portfetch::fetchfiles {args} {
</span> lappend fetch_options -u
lappend fetch_options "${fetch.user}:${fetch.password}"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${fetch.use_epsv} != "yes"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${fetch.use_epsv} ne "yes"} {
</span> lappend fetch_options "--disable-epsv"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${fetch.ignore_sslcert} != "no"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${fetch.ignore_sslcert} ne "no"} {
</span> lappend fetch_options "--ignore-ssl-cert"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${fetch.remote_time} != "no"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${fetch.remote_time} ne "no"} {
</span> lappend fetch_options "--remote-time"
}
if {$portverbose eq "yes"} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -619,7 +619,7 @@ proc portfetch::fetch_main {args} {
</span> global all_dist_files fetch.type
# Check for files, download if necessary
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {![info exists all_dist_files] && "${fetch.type}" == "standard"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {![info exists all_dist_files] && "${fetch.type}" eq "standard"} {
</span> return 0
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portlint.tcl b/src/port1.0/portlint.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index f09a644..68836f6 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portlint.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portlint.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -351,7 +351,7 @@ proc portlint::lint_main {args} {
</span> if {!$seen_portsystem} {
ui_error "Didn't find PortSystem specification"
incr errors
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {$portsystem != $lint_portsystem} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {$portsystem ne $lint_portsystem} {
</span> ui_error "Unknown PortSystem: $portsystem"
incr errors
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -373,7 +373,7 @@ proc portlint::lint_main {args} {
</span> foreach req_var $lint_required {
if {$req_var eq "master_sites"} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${fetch.type} != "standard"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${fetch.type} ne "standard"} {
</span> ui_info "OK: $req_var not required for fetch.type ${fetch.type}"
continue
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -473,7 +473,7 @@ proc portlint::lint_main {args} {
</span> foreach vconflict [ditem_key $variant conflicts] {
set exists 0
foreach v $all_variants {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$vconflict == [ditem_key $v name]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$vconflict eq [ditem_key $v name]} {
</span> set exists 1
break
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -595,14 +595,14 @@ proc portlint::lint_main {args} {
</span> }
foreach addr $maintainers {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$addr == "nomaintainer@macports.org" ||
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- $addr == "openmaintainer@macports.org"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$addr eq "nomaintainer@macports.org" ||
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $addr eq "openmaintainer@macports.org"} {
</span> ui_warn "Using full email address for no/open maintainer"
incr warnings
} elseif {[regexp "^(.+)@macports.org$" $addr -> localpart]} {
ui_warn "Maintainer email address for $localpart includes @macports.org"
incr warnings
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {$addr == "darwinports@opendarwin.org"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {$addr eq "darwinports@opendarwin.org"} {
</span> ui_warn "Using legacy email address for no/open maintainer"
incr warnings
} elseif {[regexp "^(.+)@(.+)$" $addr -> localpart domain]} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -666,13 +666,13 @@ proc portlint::lint_main {args} {
</span> }
# these checks are only valid for ports stored in the regular tree directories
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[info exists category] && $portcatdir != $category} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[info exists category] && $portcatdir ne $category} {
</span> ui_error "Portfile parent directory $portcatdir does not match primary category $category"
incr errors
} else {
ui_info "OK: Portfile parent directory matches primary category"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$portdir != $name} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$portdir ne $name} {
</span> ui_error "Portfile directory $portdir does not match port name $name"
incr errors
} else {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portstartupitem.tcl b/src/port1.0/portstartupitem.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 0191295..a4920b3 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portstartupitem.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portstartupitem.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -613,7 +613,7 @@ proc portstartupitem::startupitem_create_darwin_launchd {args} {
</span> close ${plist}
if { [getuid] == 0 &&
<span style='display:block; white-space:pre;background:#ffe0e0;'>- ${startupitem.install} != "no" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ${startupitem.install} ne "no" } {
</span> file mkdir "${destroot}/Library/${daemondest}"
ln -sf "${itemdir}/${plistname}" "${destroot}/Library/${daemondest}"
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -657,7 +657,7 @@ proc portstartupitem::startupitem_create {args} {
</span> set startupitem.type [string tolower ${startupitem.type}]
# Calculate a default value for startupitem.type
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${startupitem.type} == "default" || ${startupitem.type} == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${startupitem.type} eq "default" || ${startupitem.type} eq ""} {
</span> switch -exact ${os.platform} {
darwin {
set haveLaunchd ${portutil::autoconf::have_launchd}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -673,7 +673,7 @@ proc portstartupitem::startupitem_create {args} {
</span> }
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { ${startupitem.type} == "none" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${startupitem.type} eq "none" } {
</span> ui_notice "$UI_PREFIX [msgcat::mc "Skipping creation of control script"]"
} else {
ui_notice "$UI_PREFIX [msgcat::mc "Creating ${startupitem.type} control script"]"
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portutil.tcl b/src/port1.0/portutil.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 9873074..2c6fefe 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portutil.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portutil.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -682,7 +682,7 @@ proc variant_remove_ditem {name} {
</span> set item_index 0
foreach variant_item $all_variants {
set item_provides [ditem_key $variant_item provides]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$item_provides == $name} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$item_provides eq $name} {
</span> set all_variants [lreplace $all_variants $item_index $item_index]
break
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -786,11 +786,11 @@ proc platform {args} {
</span>
set match 0
# 'os' could be a platform or an arch when it's alone
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$len == 2 && ($os == ${os.platform} || $os == ${os.subplatform} || $os == ${os.arch})} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$len == 2 && ($os eq ${os.platform} || $os eq ${os.subplatform} || $os eq ${os.arch})} {
</span> set match 1
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {($os == ${os.platform} || $os == ${os.subplatform})
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {($os eq ${os.platform} || $os eq ${os.subplatform})
</span> && (![info exists release] || ${os.major} == $release)
<span style='display:block; white-space:pre;background:#ffe0e0;'>- && (![info exists arch] || ${os.arch} == $arch)} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ && (![info exists arch] || ${os.arch} eq $arch)} {
</span> set match 1
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1355,7 +1355,7 @@ proc target_run {ditem} {
</span> # Of course, if this is a dry run, don't do the task:
if {[tbool ports_dryrun] && $targetname ni $dryrun_allow_targets} {
# only one message per portname
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$portname != $ports_dry_last_skipped} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$portname ne $ports_dry_last_skipped} {
</span> ui_notice "For $portname: skipping $targetname (dry run)"
set ports_dry_last_skipped $portname
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1384,7 +1384,7 @@ proc target_run {ditem} {
</span>
#start tracelib
set tracing no
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {($result ==0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {($result == 0
</span> && [tbool ports_trace]
&& $target ne "clean"
&& $target ne "uninstall")} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1737,7 +1737,7 @@ proc open_statefile {args} {
</span> ui_warn "Statefile has version 2 but didn't contain a checksum"
set portfile_changed yes
} else {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$checksum_portfile != $checksum_statefile} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$checksum_portfile ne $checksum_statefile} {
</span> ui_debug "Checksum recorded in statefile '$checksum_statefile' differs from Portfile checksum '$checksum_portfile'"
set portfile_changed yes
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1768,10 +1768,10 @@ proc open_statefile {args} {
</span> set fd [open $statefile a+]
if {![tbool ports_dryrun]} {
if {[catch {adv-flock $fd -exclusive -noblock} result]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {"$result" == "EAGAIN"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$result eq "EAGAIN"} {
</span> ui_notice "Waiting for lock on $statefile"
adv-flock $fd -exclusive
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {"$result" == "EOPNOTSUPP"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {$result eq "EOPNOTSUPP"} {
</span> # Locking not supported, just return
return $fd
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1806,7 +1806,7 @@ proc get_statefile_value {class fd result} {
</span> proc check_statefile {class name fd} {
seek $fd 0
while {[gets $fd line] >= 0} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$line == "$class: $name"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$line eq "$class: $name"} {
</span> return 1
}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1829,7 +1829,7 @@ proc write_statefile {class name fd} {
</span> proc update_statefile {class name path} {
set fd [open $path r]
while {[gets $fd line] >= 0} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[lindex $line 0] != "${class}:"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[lindex $line 0] ne "${class}:"} {
</span> lappend lines $line
}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1879,7 +1879,7 @@ proc check_statefile_variants {variations oldvariations fd} {
</span> set mismatch 1
} else {
foreach key [array names upvariations *] {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {![info exists upoldvariations($key)] || $upvariations($key) != $upoldvariations($key)} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {![info exists upoldvariations($key)] || $upvariations($key) ne $upoldvariations($key)} {
</span> set mismatch 1
break
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1960,7 +1960,7 @@ proc canonicalize_variants {variants {sign "+"}} {
</span> set result ""
set vlist [lsort -ascii [array names vara]]
foreach v $vlist {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$vara($v) == $sign} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$vara($v) eq $sign} {
</span> append result "${sign}${v}"
}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2492,7 +2492,7 @@ proc addgroup {name args} {
</span> proc dirSize {dir} {
set size 0;
foreach file [readdir $dir] {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[file type [file join $dir $file]] == "link" } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[file type [file join $dir $file]] eq "link" } {
</span> continue
}
if {[file isdirectory [file join $dir $file]]} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2547,7 +2547,7 @@ proc get_portimage_name {} {
</span> set ret "${subport}-${version}_${revision}${portvariants}.${os.platform}_${os.major}.[join [get_canonical_archs] -].${portarchivetype}"
# should really look up NAME_MAX here, but it's 255 for all OS X so far
# (leave 10 chars for an extension like .rmd160 on the sig file)
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[string length $ret] > 245 && ${portvariants} != ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[string length $ret] > 245 && ${portvariants} ne ""} {
</span> # try hashing the variants
set ret "${subport}-${version}_${revision}+[rmd160 string ${portvariants}].${os.platform}_${os.major}.[join [get_canonical_archs] -].${portarchivetype}"
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2730,16 +2730,16 @@ proc extract_archive_metadata {archive_location archive_type metadata_type} {
</span> set ignore 0
continue
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[string index $line 0] != "@"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[string index $line 0] ne "@"} {
</span> lappend contents "${sep}${line}"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {$line == "@ignore"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {$line eq "@ignore"} {
</span> set ignore 1
}
}
return $contents
} elseif {$metadata_type eq "portname"} {
foreach line [split $raw_contents \n] {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[lindex $line 0] == "@portname"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[lindex $line 0] eq "@portname"} {
</span> return [lindex $line 1]
}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2807,7 +2807,7 @@ proc merge {base} {
</span> set base_arch ${arch}
}
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {"" == ${base_arch}} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {"" eq ${base_arch}} {
</span> return -code error [format [msgcat::mc "Cannot merge because directory '%s' contains no architecture directories."] ${base}]
}
ui_debug "merging architectures ${archs}, base_arch is ${base_arch}"
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2816,7 +2816,7 @@ proc merge {base} {
</span> set basepath "${base}/${base_arch}"
fs-traverse file "${basepath}" {
set fpath [string range "${file}" [string length "${basepath}"] [string length "${file}"]]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${fpath} != ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${fpath} ne ""} {
</span> # determine the type (dir/file/link)
switch [file type ${basepath}${fpath}] {
directory {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3019,7 +3019,7 @@ proc _libtest {depspec {return_match 0}} {
</span> set depname [string range $depline 0 [expr {$i - 1}]]
set depversion [string range $depline $i end]
regsub {\.} $depversion {\.} depversion
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${os.platform} == "darwin"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.platform} eq "darwin"} {
</span> set depregex \^${depname}${depversion}\\.dylib\$
} else {
set depregex \^${depname}\\.so${depversion}\$
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3102,7 +3102,7 @@ proc get_canonical_archs {} {
</span> return "noarch"
} elseif {[variant_exists universal] && [variant_isset universal]} {
return [lsort -ascii ${configure.universal_archs}]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {${configure.build_arch} != ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {${configure.build_arch} ne ""} {
</span> return ${configure.build_arch}
} else {
return ${os.arch}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3132,13 +3132,13 @@ proc check_supported_archs {} {
</span> if {$supported_archs eq "noarch"} {
return 0
} elseif {[variant_exists universal] && [variant_isset universal]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[llength ${configure.universal_archs}] > 1 || $universal_archs == ${configure.universal_archs}} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[llength ${configure.universal_archs}] > 1 || $universal_archs eq ${configure.universal_archs}} {
</span> return 0
} else {
ui_error "$subport cannot be installed for the configured universal_archs '$universal_archs' because it only supports the arch(s) '$supported_archs'."
return 1
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {$build_arch eq "" || ${configure.build_arch} != ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {$build_arch eq "" || ${configure.build_arch} ne ""} {
</span> return 0
}
ui_error "$subport cannot be installed for the configured build_arch '$build_arch' because it only supports the arch(s) '$supported_archs'."
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3280,7 +3280,7 @@ proc _archive_available {} {
</span> if {[lsearch $archive_sites macports_archives::*] == -1} {
set mirrors [lindex [split [lindex $archive_sites 0] :] 0]
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$mirrors == {}} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$mirrors eq {}} {
</span> set archive_available_result 0
return 0
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/registry2.0/portimage.tcl b/src/registry2.0/portimage.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 8230f91..5fe4641 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/registry2.0/portimage.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/registry2.0/portimage.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -175,8 +175,8 @@ proc deactivate {name {version ""} {revision ""} {variants 0} {optionslist ""}}
</span> set name [$requested name]
set specifier "[$requested version]_[$requested revision][$requested variants]"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$version ne "" && ($version != [$requested version] ||
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- ($revision ne "" && ($revision != [$requested revision] || $variants != [$requested variants])))} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$version ne "" && ($version ne [$requested version] ||
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ($revision ne "" && ($revision != [$requested revision] || $variants ne [$requested variants])))} {
</span> set v $version
if {$revision ne ""} {
append v _${revision}${variants}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -433,7 +433,7 @@ proc extract_archive_to_tmpdir {location} {
</span> }
# and finally, reinvent command_exec
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${unarchive.pipe_cmd} == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${unarchive.pipe_cmd} eq ""} {
</span> set cmdstring "${unarchive.cmd} ${unarchive.pre_args} ${unarchive.args}"
} else {
set cmdstring "${unarchive.pipe_cmd} ( ${unarchive.cmd} ${unarchive.pre_args} ${unarchive.args} )"
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -484,7 +484,7 @@ proc _activate_contents {port {imagefiles {}} {location {}}} {
</span>
set owner [registry::entry owner $file]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {$owner != {} && $owner != $port} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {$owner ne {} && $owner ne $port} {
</span> # deactivate conflicting port if it is replaced_by this one
set result [mportlookup [$owner name]]
array unset portinfo
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -507,7 +507,7 @@ proc _activate_contents {port {imagefiles {}} {location {}}} {
</span> ::file rename -force -- $file $bakfile
lappend backups $file
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { $owner != {} } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { $owner ne {} } {
</span> $owner deactivate [list $file]
$owner activate [list $file] [list "${file}${baksuffix}"]
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -515,9 +515,9 @@ proc _activate_contents {port {imagefiles {}} {location {}}} {
</span> # if we're not forcing the activation, then we bail out if
# we find any files that already exist, or have entries in
# the registry
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if { $owner != {} && $owner != $port } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { $owner ne {} && $owner ne $port } {
</span> throw registry::image-error "Image error: $file is being used by the active [$owner name] port. Please deactivate this port first, or use 'port -f activate [$port name]' to force the activation."
<span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif { $owner == {} && ![catch {::file type $file}] } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif { $owner eq {} && ![catch {::file type $file}] } {
</span> throw registry::image-error "Image error: $file already exists and does not belong to a registered port. Unable to activate port [$port name]. Use 'port -f activate [$port name]' to force the activation."
}
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/registry2.0/receipt_sqlite.tcl b/src/registry2.0/receipt_sqlite.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index ea0cf11..b6797c1 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/registry2.0/receipt_sqlite.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/registry2.0/receipt_sqlite.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -232,7 +232,7 @@ proc installed {{name ""} {version ""}} {
</span> set ports {}
set possible_ports [registry::entry imaged $name]
foreach p $possible_ports {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {"[$p version]_[$p revision][$p variants]" == $version || [$p version] == $version} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {"[$p version]_[$p revision][$p variants]" eq $version || [$p version] eq $version} {
</span> lappend ports $p
}
}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/registry2.0/registry.tcl b/src/registry2.0/registry.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 0413efa..6f1b5d9 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/registry2.0/registry.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/registry2.0/registry.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -137,7 +137,7 @@ proc property_retrieve {ref property} {
</span> proc installed {{name ""} {version ""}} {
global macports::registry.format
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${macports::registry.format} == "receipt_flat"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${macports::registry.format} eq "receipt_flat"} {
</span> set ilist [${macports::registry.format}::installed $name $version]
set rlist [list]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -175,7 +175,7 @@ proc installed {{name ""} {version ""}} {
</span> proc active {{name ""}} {
global macports::registry.format
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {${macports::registry.format} == "receipt_flat"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${macports::registry.format} eq "receipt_flat"} {
</span> set rlist [list]
set ilist [${macports::registry.format}::installed $name]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -457,7 +457,7 @@ proc convert_to_sqlite {} {
</span> foreach f $contents {
set fullpath [lindex $f 0]
# strip image dir from start
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[string range $fullpath 0 [expr {$idlen - 1}]] == $location} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[string range $fullpath 0 [expr {$idlen - 1}]] eq $location} {
</span> set path [string range $fullpath $idlen [string length $fullpath]]
} else {
set path $fullpath
</pre><pre style='margin:0'>
</pre>