[65025] trunk/base/src/macports1.0/macports.tcl
raimue at macports.org
raimue at macports.org
Fri Mar 19 09:59:35 PDT 2010
Revision: 65025
http://trac.macports.org/changeset/65025
Author: raimue at macports.org
Date: 2010-03-19 09:59:34 -0700 (Fri, 19 Mar 2010)
Log Message:
-----------
macports1.0: macportselect:
* More debug information
* Forbid to select 'base' or 'current', as that leads to problems
Modified Paths:
--------------
trunk/base/src/macports1.0/macports.tcl
Modified: trunk/base/src/macports1.0/macports.tcl
===================================================================
--- trunk/base/src/macports1.0/macports.tcl 2010-03-19 16:54:28 UTC (rev 65024)
+++ trunk/base/src/macports1.0/macports.tcl 2010-03-19 16:59:34 UTC (rev 65025)
@@ -3085,7 +3085,9 @@
switch -- $command {
list {
- if {[catch {set versions [glob -directory $conf_path *]}]} {
+ if {[catch {set versions [glob -directory $conf_path *]} result]} {
+ global errorInfo
+ ui_debug "$result: $errorInfo"
return -code error [concat "No configurations associated " \
"with '$group' were found."]
}
@@ -3104,17 +3106,19 @@
}
set {
# Use $conf_path/$version to read in sources.
- if {[catch {set src_file [open "$conf_path/$version"]}]} {
- return -code error [concat "Verify that the specified " \
- "version '$version' is valid " \
- "(i.e., Is it listed when you " \
- "specify the --list command?)."]
+ if {$version == "base" || $version == "current"
+ || [catch {set src_file [open "$conf_path/$version"]} result]} {
+ global errorInfo
+ ui_debug "$result: $errorInfo"
+ return -code error "The specified version '$version' is not valid."
}
set srcs [split [read -nonewline $src_file] "\n"]
close $src_file
# Use $conf_path/base to read in targets.
- if {[catch {set tgt_file [open "$conf_path/base"]}]} {
+ if {[catch {set tgt_file [open "$conf_path/base"]} result]} {
+ global errorInfo
+ ui_debug "$result: $errorInfo"
return -code error [concat "The configuration file " \
"'$conf_path/base' could not be " \
"opened."]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20100319/9b441666/attachment.html>
More information about the macports-changes
mailing list