USAGE for clear_depot_Map_fields.sh v1.1.1: clear_depot_Map_fields.sh [-i <instance>] [-L <log>] [-v<n>] [-p|-n] [-D] or clear_depot_Map_fields.sh [-h|-man|-V] DESCRIPTION: This script obsoletes the SetDefaultDepotSpecMapField.py trigger. It does so by following a series of steps. First, it ensures that the configurable server.depot.root is set correctly, setting it is not set. Next, the Triggers table is checked to ensure the call to the SetDefaultDepotSpecMapField.py is not called; it is deleted from the Triggers table if found. Last, it resets the 'Map:' field of depot specs for depot types where that is appropriate, setting it to the default value of '<DepotName>/...', so that it honors the server.depot.root configruable. This is done for depots of these types: * stream * local * spec * unload but not these: * unload * remote * graph If an unknown depot type is encountered, the Map field is reset as well if it is set. This script does a preflight check first, reporting any cases where the starting conditions are not as expected, such as. These are treated as Warnings: * Configurable server.depot.root is already set * SetDefaultDepotSpecMapField.py not found in triggers * Depot already has Map field set to the default <DepotName>/... These conditions are treated as Errors, and will abort processing: * Depot Map field set to something other than the default. * Configurable server.depot.root is set, but to something other than what it should be. OPTIONS: -v<n> Set verbosity 1-5 (-v1 = quiet, -v5 = highest). -L <log> Specify the path to a log file, or the special value 'off' to disable logging. By default, all output (stdout and stderr) goes to EDITME_DEFAULT_LOG NOTE: This script is self-logging. That is, output displayed on the screen is simultaneously captured in the log file. Do not run this script with redirection operators like '> log' or '2>&1', and do not use 'tee.' -p Run preflight checks only, and then stop. By default, actual changes occur if preflight checks find no issues. -n No-Op. No actions are taken that would affect data significantly; instead commands are displayed rather than executed. -D Set extreme debugging verbosity. HELP OPTIONS: -h Display short help message -man Display man-style help message -V Dispay version info for this script and its libraries. EXAMPLES: A typical flow for this script is to do a preflight first, and then a live run, for any given instance: clear_depot_Map_fields.sh -i 1 -p clear_depot_Map_fields.sh -i 1 Note that if using '-n', the '-v5' flag should also be used.
Released SDP 2019.3.26159 (2019/11/06).
Copy Up using 'p4 copy -r -b perforce_software-sdp-dev'.
Added script to deprecate the SetDefaultDepotSpecMapField.py, useful
when upgrading from older SDP environments.
This will be deployed in into a new /p4/common/upgrade_sdp directory,
separate from /p4/common/bin, as is a one-time-per-data set script
only done as part of the SDP upgrade process. Actually getting this
deployed will require a tweak to mkdirs.sh, which will be coming