1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | const fs = require("fs");
|
4 | exports.getProjectId = () => {
|
5 | try {
|
6 | const config = JSON.parse(fs.readFileSync('./.dogcli', 'utf8'));
|
7 | if (config.projectId === undefined) {
|
8 | throw Error('AppId not selected');
|
9 | }
|
10 | return config.projectId;
|
11 | }
|
12 | catch (e) {
|
13 | console.log(`
|
14 | This directory doesn't seem to be initialized for deployment.
|
15 |
|
16 | Either run this command again from the root of your project or initialize this project with the following command:
|
17 |
|
18 | dog apps:init
|
19 | `);
|
20 | process.exit(1);
|
21 | }
|
22 | };
|