OSDN Git Service

[BUG FIX] The message about the evaluated dependency level in show command was wrong.
authorMamoru Sakaue / MwGhennndo <glmwghennndo@users.sourceforge.jp>
Sat, 4 Aug 2018 10:22:56 +0000 (18:22 +0800)
committerMamoru Sakaue / MwGhennndo <glmwghennndo@users.sourceforge.jp>
Sat, 4 Aug 2018 10:22:56 +0000 (18:22 +0800)
 Changes to be committed:
modified:   lib/libcommand_show.sh
modified:   lib/libdatabase_query.sh
modified:   lib/libmain.sh
modified:   lib/libmessage.sh
modified:   man/portsreinstall.8

lib/libcommand_show.sh
lib/libdatabase_query.sh
lib/libmain.sh
lib/libmessage.sh
man/portsreinstall.8

index fc78dd7..c6af4dc 100644 (file)
@@ -31,9 +31,6 @@ command_show ()
                list=requirements.$dbsuffix
                listdb='initial'
                pkgnamedb='initial'
-               [ $COMMAND_SHOW_DEPTAG = none ] && \
-                       message_echo "WARNING: This command has no meaning with the current options setting." >&2
-               database_query_show_port_lists "$grandtitle" "$title" "$list" "$listdb" "$pkgnamedb" "$@"
                ;;
        requirements )
                grandtitle="Dependencies based on the latest ports tree"
@@ -41,9 +38,6 @@ command_show ()
                list=requirements.$dbsuffix
                listdb='requires'
                pkgnamedb='moved_from'
-               [ $COMMAND_SHOW_DEPTAG = none ] && \
-                       message_echo "WARNING: This command has no meaning with the current options setting." >&2
-               database_query_show_port_lists "$grandtitle" "$title" "$list" "$listdb" "$pkgnamedb" "$@"
                ;;
        initdependents )
                grandtitle="Dependencies based on the initially installed packages"
@@ -51,9 +45,6 @@ command_show ()
                list=dependents.$dbsuffix
                listdb='initial'
                pkgnamedb='initial'
-               [ $COMMAND_SHOW_DEPTAG = none ] && \
-                       message_echo "WARNING: This command has no meaning with the current options setting." >&2
-               database_query_show_port_lists "$grandtitle" "$title" "$list" "$listdb" "$pkgnamedb" "$@"
                ;;
        dependents )
                grandtitle="Dependencies based on the latest ports tree"
@@ -61,9 +52,6 @@ command_show ()
                list=dependents.$dbsuffix
                listdb='requires'
                pkgnamedb='moved_from'
-               [ $COMMAND_SHOW_DEPTAG = none ] && \
-                       message_echo "WARNING: This command has no meaning with the current options setting." >&2
-               database_query_show_port_lists "$grandtitle" "$title" "$list" "$listdb" "$pkgnamedb" "$@"
                ;;
        conflict_files )
                grandtitle="Possible additional conflict files"
@@ -88,4 +76,11 @@ command_show ()
                database_query_show_log "$grandtitle" "$title" "$list" "$listdb" "$pkgnamedb" "$@"
                ;;
        esac
+       case $COMMAND_SHOW_SUBJECT in
+       initrequirements | requirements | initdependents | dependents )
+               [ $COMMAND_SHOW_DEPTAG = none ] && \
+                       message_echo "WARNING: This command has no meaning with the current options setting." >&2
+               database_query_show_port_lists "$grandtitle" "$title" "$list" "$listdb" "$pkgnamedb" "$COMMAND_SHOW_DEPTAG" "$COMMAND_SHOW_LEVEL" "$@"
+               ;;
+       esac
 }
index a2fc6a1..6d30282 100644 (file)
@@ -293,7 +293,7 @@ database_query_show_list_inclusion_of_matching_port ()
        level=$5
        shift 5
        message_echo "[$grandtitle]"
-       message_dependency_scope
+       message_dependency_scope "$deptag" "$level"
        message_echo
        isfirst=y
        for origin_target in `pkgsys_eval_ports_glob "$@"`
@@ -332,15 +332,17 @@ database_query_show_list_inclusion_of_matching_port ()
 # ============= Output of "show" command for port lists =============
 database_query_show_port_lists ()
 {
-       local grandtitle title list listdb pkgnamedb isfirst origin_target pkg_target table_target list_target
+       local grandtitle title list listdb pkgnamedb deptag level isfirst origin_target pkg_target table_target list_target
        grandtitle=$1
        title=$2
        list=$3
        listdb=$4
        pkgnamedb=$5
-       shift 5
+       deptag=$6
+       level=$7
+       shift 7
        message_echo "[$grandtitle]"
-       message_dependency_scope
+       message_dependency_scope "$deptag" "$level"
        message_echo
        isfirst=y
        for origin_target in `pkgsys_eval_ports_glob "$@"`
@@ -584,7 +586,7 @@ database_query_show_single_list_exec ()
        todo )
                message_echo "The following ports remain in the (re)installation queue for the current do/redo process:"
                message_echo "It is noted that ports to be skipped can be included here."
-               message_dependency_scope
+               message_dependency_scope "$deptag" "$level"
                message_echo
                list=stage.loop_list/reinst_todo.remain
                [ ${DBDIR}/reinst_order.list -nt ${DBDIR}/$list ] && list=reinst_order.list
@@ -593,7 +595,7 @@ database_query_show_single_list_exec ()
                ;;
        done )
                message_echo "The following ports have been successfully (re)installed or newly installed:"
-               message_dependency_scope
+               message_dependency_scope "$deptag" "$level"
                message_echo
                list=success.$dbsuffix.list
                flag_filter_skip_unchanged=necessary_upgrade_completed.$dbsuffix
@@ -601,7 +603,7 @@ database_query_show_single_list_exec ()
                ;;
        redo )
                message_echo "The following ports need (re)installation but are to be skipped until any of their failed requirements succeeds:"
-               message_dependency_scope
+               message_dependency_scope "$deptag" "$level"
                message_echo
                list=todo_after_requirements_succeed.$dbsuffix.list
                flag_filter_skip_unchanged=necessary_upgrade.$dbsuffix
index d4ebe44..ee7ac24 100644 (file)
@@ -12,7 +12,7 @@ main_set_version ()
        MYVERSION=4.1.0
        COMPATIBLE_VERSIONS='^(4\.[0-1]\.[0-9])$'
        # Template for development versions
-       MYVERSION=4.0.0+toward_4.1.0_20180802204253
+       MYVERSION=4.0.0+toward_4.1.0_20180804182236
        COMPATIBLE_VERSIONS='^(4\.[0-1]\.[0-9]]|4\.[0]\.[0]+(|\+toward_4\.[0-1]\.[0-9]+_[0-9]+))$'
 }
 
index d26b11f..9a538b2 100644 (file)
@@ -229,6 +229,9 @@ message_summary_dependents_of_failed_reinstallation ()
 # ============= Show a message of a dependency scope =============
 message_dependency_scope ()
 {
+       local deptag level
+       deptag=$1
+       level=$2
        ( set -e
                options_parse_dependency_type "$deptag"
                options_parse_dependency_level "$level"
index 387f14d..6129ba8 100644 (file)
@@ -1132,6 +1132,8 @@ Configuration file of \fBportupgrade\fR(1).
 [BUG FIX] Evaluation of globs was incorrect for the regular expression form.
 .PP
 [BUG FIX] Flavored requirements were incorrectly inspected. This also caused disability of the use of prebuilt official packages for flavord ports with the default configuration. 
+.PP
+[BUG FIX] The message about the evaluated dependency level in \fBshow\fR command was wrong. 
 .RE
 .TP
 4.0.0 (29 June 2018)