OSDN Git Service

d6cf30d08cb526820bce37ff354abe760b248505
[portsreinstall/current.git] / lib / upgrade / libusage.sh
1 #!/bin/sh -e
2 # ==============================================================================
3 # portsreinstall library script
4 # Overlay onto lib/libusage.sh for portsreinstall-upgrade
5 # - Help messages -
6 # Copyright (C) 2018 Mamoru Sakaue, MwGhennndo, All Rights Reserved.
7 # This software is distributed under the 2-Clause BSD License.
8 # ==============================================================================
9
10 # ============= Content of the short help =============
11 usage_short_content ()
12 {
13         cat << eof
14 USAGE: ${APPNAME} [OPTIONS] [--] [command]
15
16 [OPTIONS]
17  <Group 1: Just show messages and exit without operation>
18  -H : Show a long help whose content is the same as the manual page.
19  -h : Show this short help.
20  -V : Show the current version.
21  <Group 2: Effective anytime>
22  -a : Suppress messages to be batch-friendly.
23  -M : Reset group 4 option settings.
24  -S : Suppress the credit and opening messages.
25  <Group 3: Saved and transferred to restarted runs, renewable by -M option>
26  -c : Suppress cleaning the temporary database even if its obsolete.
27  -n : No operation is carried out (just for seeing what will be done).
28  <Group 4: Saved and not renewable until cleaning>
29  -P : Directory where the updated packages are located (\${PACKAGES}/\${PKGREPOSITORYSUBDIR} by default (which is usually /usr/ports/packages/All)
30
31 [ARGUMENTS]
32  command:database_maintain_save
33             do (default)
34           | clean [normal] | clean force
35           | options
36
37 [DESCRIPTIONS]
38  This utility is dispatched from a builder environment to target environments for upgrading packages.
39
40 [ROBUSTNESS AGAINST TERMINATION AND RESTART]
41  Execution of this utility can be terminated at any points and restarted from there with the same options saved in the temporary database (independent among utilities). The saved options can be changed by the ways depending on the assigned groups of the options. The options and execution progress are reset to the default by running with "-R" option.
42 eof
43 }