<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/12a2166c3a22d82a4d4a766a7b115a8bdfd36325">https://github.com/macports/macports-base/commit/12a2166c3a22d82a4d4a766a7b115a8bdfd36325</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit 12a2166c3a22d82a4d4a766a7b115a8bdfd36325
</span>Author: Joshua Root <jmr@macports.org>
AuthorDate: Sun Aug 28 09:29:33 2022 +1000
<span style='display:block; white-space:pre;color:#404040;'> Clean up some unneeded exprs
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Also add -exact to an lsearch that doesn't need to glob.
</span>---
src/port1.0/portutil.tcl | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
<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 9697dca6..5bb49878 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;'>@@ -567,7 +567,7 @@ proc handle_option_string {option action args} {
</span> }
# Remove indent on first line
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set arg [string replace $arg 0 [expr {$i - 1}]]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set arg [string replace $arg 0 $i-1]
</span> # Remove indent on each other line
set arg [string map "\"\n$indent\" \"\n\"" $arg]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -600,7 +600,7 @@ proc variant {args} {
</span> return -code error "Malformed variant specification"
}
set code [lindex $args end]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set args [lrange $args 0 [expr {$len - 2}]]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set args [lrange $args 0 end-1]
</span>
set ditem [variant_new "temp-variant"]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -816,7 +816,7 @@ proc platform {args} {
</span> }
set code [lindex $args end]
set os [lindex $args 0]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set args [lrange $args 1 [expr {$len - 2}]]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set args [lrange $args 1 end-1]
</span>
set release_re {(^[0-9]+$)}
set arch_re {([a-zA-Z0-9]*)}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1269,7 +1269,7 @@ proc ln {args} {
</span> set files $args
set target ./
} else {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set files [lrange $args 0 [expr {[llength $args] - 2}]]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set files [lrange $args 0 end-1]
</span> set target [lindex $args end]
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3058,7 +3058,7 @@ proc fileAttrsAsRoot {file attributes} {
</span> }
} else {
# not root, so can't set owner/group
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set permissions [lindex $attributes [expr {[lsearch $attributes "-permissions"] + 1}]]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set permissions [lindex $attributes [lsearch -exact $attributes "-permissions"]+1]
</span> file attributes $file -permissions $permissions
}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3181,7 +3181,7 @@ proc _libtest {depspec {return_match 0}} {
</span>
set i [string first . $depline]
if {$i < 0} {set i [string length $depline]}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set depname [string range $depline 0 [expr {$i - 1}]]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set depname [string range $depline 0 $i-1]
</span> set depversion [string range $depline $i end]
regsub {\.} $depversion {\.} depversion
if {${os.platform} eq "darwin"} {
</pre><pre style='margin:0'>
</pre>