@cloudcommerce/cli 0.0.43 → 0.0.44

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.
@@ -1,5 +1,5 @@
1
- @cloudcommerce/cli:build: cache hit, replaying output 68a740620743ff16
2
- @cloudcommerce/cli:build: 
3
- @cloudcommerce/cli:build: > @cloudcommerce/cli@0.0.42 build /home/leo/code/ecomplus/cloud-commerce/packages/cli
4
- @cloudcommerce/cli:build: > sh ../../scripts/build-lib.sh
5
- @cloudcommerce/cli:build: 
1
+ @cloudcommerce/cli:build: cache hit, replaying output 2cf4cee828b155a9
2
+ @cloudcommerce/cli:build: 
3
+ @cloudcommerce/cli:build: > @cloudcommerce/cli@0.0.43 build /home/leo/code/ecomplus/cloud-commerce/packages/cli
4
+ @cloudcommerce/cli:build: > sh ../../scripts/build-lib.sh
5
+ @cloudcommerce/cli:build: 
package/lib/build.js CHANGED
@@ -8,8 +8,11 @@ const copyFunctionsConfig = async () => {
8
8
  for (let i = 0; i < dirents.length; i++) {
9
9
  if (dirents[i].isDirectory() && dirents[i].name.charAt(0) !== '.') {
10
10
  for (let ii = 0; ii < filesToCopy.length; ii++) {
11
- // eslint-disable-next-line no-await-in-loop
12
- await fs.copy(path.join(functionsDir, filesToCopy[ii]), path.join(functionsDir, dirents[i].name, filesToCopy[ii]));
11
+ const srcPath = path.join(functionsDir, filesToCopy[ii]);
12
+ if (fs.existsSync(srcPath)) {
13
+ // eslint-disable-next-line no-await-in-loop
14
+ await fs.copy(srcPath, path.join(functionsDir, dirents[i].name, filesToCopy[ii]));
15
+ }
13
16
  }
14
17
  }
15
18
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@cloudcommerce/cli",
3
3
  "type": "module",
4
- "version": "0.0.43",
4
+ "version": "0.0.44",
5
5
  "description": "E-Com Plus Cloud Commerce CLI tools",
6
6
  "bin": {
7
7
  "cloudcommerce": "./bin/run.mjs"
@@ -23,7 +23,7 @@
23
23
  },
24
24
  "homepage": "https://github.com/ecomplus/cloud-commerce/tree/main/packages/cli#readme",
25
25
  "dependencies": {
26
- "@cloudcommerce/api": "0.0.43",
26
+ "@cloudcommerce/api": "0.0.44",
27
27
  "md5": "^2.3.0",
28
28
  "zx": "^7.0.7"
29
29
  },
package/src/build.ts CHANGED
@@ -8,11 +8,14 @@ const copyFunctionsConfig = async () => {
8
8
  for (let i = 0; i < dirents.length; i++) {
9
9
  if (dirents[i].isDirectory() && dirents[i].name.charAt(0) !== '.') {
10
10
  for (let ii = 0; ii < filesToCopy.length; ii++) {
11
- // eslint-disable-next-line no-await-in-loop
12
- await fs.copy(
13
- path.join(functionsDir, filesToCopy[ii]),
14
- path.join(functionsDir, dirents[i].name, filesToCopy[ii]),
15
- );
11
+ const srcPath = path.join(functionsDir, filesToCopy[ii]);
12
+ if (fs.existsSync(srcPath)) {
13
+ // eslint-disable-next-line no-await-in-loop
14
+ await fs.copy(
15
+ srcPath,
16
+ path.join(functionsDir, dirents[i].name, filesToCopy[ii]),
17
+ );
18
+ }
16
19
  }
17
20
  }
18
21
  }