@datapos/datapos-development 0.3.12 → 0.3.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +4 -4
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -7,8 +7,8 @@ const util = require('util');
7
7
  const exec = util.promisify(require('child_process').exec);
8
8
 
9
9
  // Operations - Build Configuration
10
- async function buildConfig() {
11
- const configJSON = await readJSONFile('src/config.json');
10
+ async function buildConfig(directoryPath) {
11
+ const configJSON = await readJSONFile(`${directoryPath}config.json`);
12
12
  const packageJSON = await readJSONFile('package.json');
13
13
  await fs.writeFile('src/config.json', JSON.stringify({ ...configJSON, id: packageJSON.name, version: packageJSON.version }, undefined, 4));
14
14
  }
@@ -84,7 +84,7 @@ async function sendDeploymentNotice() {
84
84
  headers: { 'Content-Type': 'application/json' },
85
85
  method: 'PUT'
86
86
  };
87
- const response = await fetch(`https://operations.datapos.app/states/${configJSON.id}`, options);
87
+ const response = await fetch(`https://api.datapos.app/states/${configJSON.id}`, options);
88
88
  if (!response.ok) console.log(await response.text());
89
89
  }
90
90
 
@@ -134,7 +134,7 @@ async function uploadModuleConfig() {
134
134
  headers: { 'Content-Type': 'application/json' },
135
135
  method: 'PUT'
136
136
  };
137
- const response = await fetch(`https://operations.datapos.app/states/${stateId}`, options);
137
+ const response = await fetch(`https://api.datapos.app/states/${stateId}`, options);
138
138
  if (!response.ok) console.log(await response.text());
139
139
  }
140
140
 
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "index.js",
7
- "version": "0.3.12",
7
+ "version": "0.3.14",
8
8
  "devDependencies": {
9
9
  "eslint": "^9.28.0",
10
10
  "nanoid": "^5.1.5",