Skip to content

Commit 0ab43ff

Browse files
committed
[static] make it bwd-compatible
Signed-off-by: Itai Segall <itai.segall@digitalasset.com>
1 parent f21b80c commit 0ab43ff

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

build-tools/cncluster

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2122,12 +2122,13 @@ function subcmd_purge_unused_dbs() {
21222122
subcommand_whitelist[set_operator_deployment_reference]="Set the git reference for the operator deployment in the cluster config file"
21232123
function subcmd_set_operator_deployment_reference() {
21242124

2125-
if [ "$#" -lt 2 ]; then
2126-
echo "Usage: $0 set_operator_deployment_reference <branch>"
2125+
# TODO(#1062): remove the ignored parameter once the base version for migration tests is >= 0.4.2
2126+
if [ "$#" -lt 1 ]; then
2127+
echo "Usage: $0 set_operator_deployment_reference <branch> [<ignored>]"
21272128
exit 1
21282129
fi
21292130
if [ "$#" -gt 2 ]; then
2130-
echo "Usage: $0 set_operator_deployment_reference <branch>"
2131+
echo "Usage: $0 set_operator_deployment_reference <branch> [<ignored>]"
21312132
exit 1
21322133
fi
21332134
deployment_config=$(cat <<EOF

build-tools/lib/hard-domain-migration-commands

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ function subcmd_update_config() {
1919
migration_id="$2"
2020
shift 2
2121
else
22-
_error "Usage: $0 $SCRIPTNAME migration_type migration_id [version] [<git_reference> <git_repo>]"
22+
# TODO(#1062): remove the ignored parameter once the base version for migration tests is >= 0.4.2
23+
_error "Usage: $0 $SCRIPTNAME migration_type migration_id [version] [<git_reference> [<ignored>]]"
2324
fi
2425
local migration_config
2526
migration_config=$(cat <<EOF
@@ -34,17 +35,17 @@ EOF
3435
)
3536
shift
3637
fi
38+
# TODO(#1062): remove the ignored parameter once the base version for migration tests is >= 0.4.2
3739
if [ "$#" -gt 0 ]; then
38-
if [ "$#" -lt 2 ]; then
39-
_error "Usage: $0 $SCRIPTNAME migration_type migration_id [version] [<git_reference> <git_repo>]"
40+
if [ "$#" -lt 1 ]; then
41+
_error "Usage: $0 $SCRIPTNAME migration_type migration_id [version] [<git_reference> [<ignored>]]"
4042
fi
4143
git_reference="$1"
42-
git_repo="$2"
4344
shift
4445
migration_config+=$(cat <<EOF
4546
4647
releaseReference:
47-
$(_get_flux_reference_config $git_reference $git_repo " ")
48+
$(_get_flux_reference_config $git_reference " ")
4849
EOF
4950
)
5051
fi

0 commit comments

Comments
 (0)