Skip to content

Commit b6f35af

Browse files
author
Artem
committed
Overwrite UPGRADES_LINK using circle instead of extra logic
1 parent 800c53c commit b6f35af

File tree

2 files changed

+4
-14
lines changed

2 files changed

+4
-14
lines changed

.circleci/config.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ jobs:
432432
exit 0;
433433
fi
434434
435-
SEGMENT_WRITE_KEY=$SEGMENT_WRITE_KEY_STAGE yarn package:<< parameters.env >>
435+
UPGRADES_LINK=UPGRADES_LINK_STAGE SEGMENT_WRITE_KEY=$SEGMENT_WRITE_KEY_STAGE yarn package:<< parameters.env >>
436436
- persist_to_workspace:
437437
root: .
438438
paths:
@@ -474,7 +474,7 @@ jobs:
474474
exit 0;
475475
fi
476476
477-
SEGMENT_WRITE_KEY=$SEGMENT_WRITE_KEY_STAGE yarn package:<< parameters.env >>
477+
UPGRADES_LINK=UPGRADES_LINK_STAGE SEGMENT_WRITE_KEY=$SEGMENT_WRITE_KEY_STAGE yarn package:<< parameters.env >>
478478
rm -rf release/mac
479479
no_output_timeout: 15m
480480
- persist_to_workspace:
@@ -514,7 +514,7 @@ jobs:
514514
exit 0;
515515
fi
516516
517-
SEGMENT_WRITE_KEY=$SEGMENT_WRITE_KEY_STAGE yarn package:<< parameters.env >>
517+
UPGRADES_LINK=UPGRADES_LINK_STAGE SEGMENT_WRITE_KEY=$SEGMENT_WRITE_KEY_STAGE yarn package:<< parameters.env >>
518518
rm -rf release/win-unpacked
519519
shell: bash.exe
520520
no_output_timeout: 20m

redisinsight/main.dev.ts

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -119,17 +119,7 @@ const bootstrap = async () => {
119119
trayInstance = tray.buildTray();
120120
}
121121

122-
let upgradeUrl;
123-
switch (process.env.NODE_ENV) {
124-
case 'production':
125-
upgradeUrl = process.env.MANUAL_UPGRADES_LINK || process.env.UPGRADES_LINK;
126-
break;
127-
case 'staging':
128-
upgradeUrl = process.env.MANUAL_UPGRADES_LINK || process.env.UPGRADES_LINK_STAGE;
129-
break;
130-
default:
131-
upgradeUrl = process.env.MANUAL_UPGRADES_LINK || '';
132-
}
122+
const upgradeUrl = process.env.MANUAL_UPGRADES_LINK || process.env.UPGRADES_LINK;
133123

134124
if (upgradeUrl) {
135125
new AppUpdater(upgradeUrl);

0 commit comments

Comments
 (0)