Skip to content

Commit

Permalink
MA-15096: added odr_runtime parameter
Browse files Browse the repository at this point in the history
MA-15096: added odr_runtime parameter

MA-15096: added odr_runtime parameter
  • Loading branch information
AlekseiKochetkov committed Nov 27, 2023
1 parent dac181a commit 69b6743
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
13 changes: 12 additions & 1 deletion bin/vk-miniapps-deploy
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ async function run() {
const extraOptions = await getExtraOptions()
cfg.update_prod = extraOptions.update_prod;
cfg.update_dev = extraOptions.update_dev;
cfg.odr_runtime = extraOptions.odr_runtime;

if (extraOptions.update_test === true && extraOptions.test_group_name !== '') {
cfg.test_group_name = extraOptions.test_group_name;
Expand Down Expand Up @@ -81,12 +82,22 @@ async function getExtraOptions() {
type: prev => prev === true ? 'text' : null,
name: 'test_group_name',
message: chalk.yellow('Enter test group name:')
},
{
type: 'text',
name: 'odr_runtime',
message: 'What version of ODR runtime is used (v1/v2)?'
}
];

const extraOptions = await prompt(questions);

if (extraOptions.update_prod === false && extraOptions.update_dev === false && extraOptions.update_test === false) {
if (
extraOptions.update_prod === false
&& extraOptions.update_dev === false
&& extraOptions.update_test === false
&& extraOptions.odr_runtime === ''
) {
process.exit();
}

Expand Down
3 changes: 3 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,9 @@ async function run(cfg) {
if ('test_group_name' in cfg) {
params.test_group_name = cfg.test_group_name
}
if ('odr_runtime' in cfg && cfg.odr_runtime !== '') {
params.odr_runtime = cfg.odr_runtime;
}

const endpointPlatformKeys = Object.keys(cfg.endpoints);
if (endpointPlatformKeys.length) {
Expand Down

0 comments on commit 69b6743

Please sign in to comment.