Skip to content

Commit

Permalink
Make port diagnose less verbose
Browse files Browse the repository at this point in the history
Print "Checking for ..." messages at info level. Don't print one for
every installed port. Don't print anything for the X11.app on 10.6
check when not on 10.6.

(cherry picked from commit 741a77b)
  • Loading branch information
jmroot committed Feb 17, 2017
1 parent a5c8a42 commit 52fa086
Showing 1 changed file with 10 additions and 20 deletions.
30 changes: 10 additions & 20 deletions src/macports1.0/diagnose.tcl
Expand Up @@ -215,7 +215,7 @@ namespace eval diagnose {
# None

if {!${diagnose::quiet}} {
ui_msg -nonewline "Checking for $string... "
ui_info -nonewline "Checking for $string... "
}
}

Expand All @@ -232,11 +232,11 @@ namespace eval diagnose {

if {$result == 1} {

ui_msg "\[SUCCESS\]"
ui_info "\[SUCCESS\]"
return
}

ui_msg "\[FAILED\]"
ui_info "\[FAILED\]"
}
}

Expand Down Expand Up @@ -443,17 +443,11 @@ namespace eval diagnose {
# Returns:
# None

set apps [registry::entry imaged]

foreach app $apps {
set name [$app name]
output "'${name} @[$app version]_[$app revision][$app variants]'s tarball on disk"
set ports [registry::entry imaged]

if {![file exists [$app location]]} {
ui_warn "couldn't find the archive for '$name'. Please uninstall and reinstall this port."
success_fail 0
} else {
success_fail 1
foreach port $ports {
if {![file exists [$port location]]} {
ui_warn "couldn't find the archive for '[$port name] @[$port version]_[$port revision][$port variants]'. Please uninstall and reinstall this port."
}
}
}
Expand Down Expand Up @@ -504,11 +498,8 @@ namespace eval diagnose {
# Returns:
# None

output "X11.app on OS X 10.6 systems"

set mac_version ${macports::macosx_version}

if {$mac_version eq "10.6"} {
if {${macports::macosx_version} eq "10.6"} {
output "X11.app on OS X 10.6 systems"

if {[file exists /Applications/X11.app]} {
ui_error "it seems you have Mac OS X 10.6 installed, and are using X11 from \"X11.app\". This has been known to cause issues. \
Expand All @@ -518,9 +509,8 @@ namespace eval diagnose {
success_fail 0
return
}
success_fail 1
}

success_fail 1
}

proc check_free_space {} {
Expand Down

0 comments on commit 52fa086

Please sign in to comment.