Skip to content

Commit a0b8155

Browse files
committed
Adjust deploy-if-needed script
1 parent 26ecafb commit a0b8155

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.github/workflows/deploy-config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,4 @@ jobs:
4545
run: yarn ts-node scripts/ci-test/deploy-if-needed.ts
4646
env:
4747
FIREBASE_CLI_TOKEN: ${{secrets.FIREBASE_CLI_TOKEN}}
48+
PROJECT_CONFIG: ${{ secrets.TEST_PROJECT_CONFIG }}

scripts/ci-test/deploy-if-needed.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ import { exec } from 'child-process-promise';
2222
const firebaseTools = require('firebase-tools');
2323

2424
const root = resolve(__dirname, '../..');
25-
const config = require(resolve(root, 'config/ci.config.json'));
2625
const git = simpleGit(root);
2726

2827
interface DeployOptions {
@@ -32,6 +31,11 @@ interface DeployOptions {
3231
only?: string;
3332
}
3433

34+
let config: { projectId: string };
35+
if (process.env.PROJECT_CONFIG) {
36+
config = JSON.parse(process.env.PROJECT_CONFIG);
37+
}
38+
3539
/**
3640
* Changes to these files require redeployment to the project backend.
3741
*/

0 commit comments

Comments
 (0)