command_do_update_host_files ()
{
local dirpath filepath
- message_echo "Updating the files affecting package installation (packages, distfiles, port options, ports/packages management tools configurations) of the host environment..."
+ message_section_title "Update the files affecting package installation of the host environment"
+ message_echo "INFO: targets are packages, distfiles, port options and ports/packages management tools configurations"
for dirpath in "${DISTDIR}" "${PACKAGES}" "${PORT_DBDIR}"
do
(
rm -f $filepath
fi
done
- :
+ message_echo
}
# ============= Ending process =============
program_exec_and_record_completion STARTER_GUEST_PKG_REPO
}
-# ============= Starter process in the chroot environment: Initiate the reinstallation process =============
-command_do_starter_init_resinst ()
+# ============= Starter process in the chroot environment: Clean the temporary database =============
+command_do_starter_clean ()
{
local PROGRAM_DEPENDS
PROGRAM_DEPENDS='STARTER_GUEST_PKG_REPO'
_program_exec_and_record_completion__operation ()
{
+ local opts
+ [ $opt_fullcourse = no ] && return
+ message_section_title "Full course starter: Clean the temporary database"
+ if [ $opt_batch_mode = no ]
+ then
+ opts=
+ else
+ opts='-q'
+ fi
+ chroot "$opt_basedir"/builder /usr/bin/env ${PROGRAM} $opts clean force
+ message_echo
+ }
+ program_exec_and_record_completion STARTER_GUEST_CLEAN
+}
+
+# ============= Main process in the chroot environment: Initiate the reinstallation process =============
+command_do_main_init_resinst ()
+{
+ local PROGRAM_DEPENDS
+ PROGRAM_DEPENDS='STARTER_GUEST_CLEAN'
+ _program_exec_and_record_completion__operation ()
+ {
local exitstatus
[ $opt_fullcourse = no ] && return
- message_section_title "Full course starter: Initiate the reinstallation process"
+ message_section_title "Full course main: Initiate the reinstallation process"
if [ $opt_batch_mode = no ]
then
opts='-CGSYjqx'
PROGRAM_DEPENDS='UPGRADE_GUEST'
_program_exec_and_record_completion__operation ()
{
- message_echo "Packing the upgrades..."
+ message_section_title "Pack the upgrades"
[ $opt_batch_mode = yes ] && opt_quiet='-a '
chroot "$opt_basedir"/builder /bin/csh -c "${PROGRAM} -S $opt_quiet packupgrade create && ${PROGRAM} -S $opt_quiet packupgrade crop /.${PROGRAM}"
}
PROGRAM_DEPENDS='UPDATE_HOST'
_program_exec_and_record_completion__operation ()
{
- message_echo "Extracting the upgrade archive..."
+ message_section_title "Extract the upgrade archive"
(
cd "$opt_basedir"/store
rm -rf work
PROGRAM_DEPENDS='EXTRACT_SCRIPT_ARCHIVE'
_program_exec_and_record_completion__operation ()
{
- message_echo "Updating the packages at the host environment..."
+ message_section_title "Update the packages at the host environment"
(
cd "$opt_basedir"/store
opt_quiet=