Skip to content
Permalink
Browse files

macports1.0: Fix typos and logic errors in migrate

'port migrate' cannot call portindex when running selfupdate, because
portindex will refuse to work due to the platform mismatch.
  • Loading branch information
neverpanic committed Mar 11, 2018
1 parent 8c99f40 commit 7eda6cf961bc10af9d755cd2c73843d4cfe50ee3
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/macports1.0/migrate.tcl
@@ -77,7 +77,7 @@ namespace eval migrate {
# If port migrate was not called with --continue, the user probably did
# that manually and we do not have confirmation to run migration yet;
# do that now.
set continuation [expr {[info exists options(ports_migration_continue)] && $options(ports_migration_continue)}]
set continuation [expr {[info exists options(ports_migrate_continue)] && $options(ports_migrate_continue)}]
if {!$continuation && [info exists macports::ui_options(questions_yesno)]} {
set msg "Migration will reinstall all installed ports."
set retvalue [$macports::ui_options(questions_yesno) $msg "MigrationContinuationPrompt" "" {y} 0 "Would you like to continue?"]
@@ -159,8 +159,10 @@ namespace eval migrate {
array set optionslist {}
# Force rebuild, but do not allow downgrade
set optionslist(ports_selfupdate_migrate) 1
# Avoid portindex, which would trigger 'portindex', which does not work
set optionslist(ports_selfupdate_nosync) 1

uplevel [list selfupdate::main [array get optionslist] base_updated]
selfupdate::main [array get optionslist] base_updated
return $base_updated
}
}

0 comments on commit 7eda6cf

Please sign in to comment.
You can’t perform that action at this time.