@cocreate/cli 1.46.0 → 1.47.0
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.
- package/CHANGELOG.md +15 -0
- package/package.json +4 -4
- package/src/commands/link.js +1 -0
- package/src/commands/other/nfs.js +40 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
# [1.47.0](https://github.com/CoCreate-app/CoCreate-cli/compare/v1.46.1...v1.47.0) (2024-01-08)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* bumped CoCreate dependencies to their latest versions ([ae609a8](https://github.com/CoCreate-app/CoCreate-cli/commit/ae609a859ef5620acfa998292feea25d37262534))
|
|
7
|
+
* nfs.js to mount disk ([69efc0a](https://github.com/CoCreate-app/CoCreate-cli/commit/69efc0a97cb1d0c5ec670c02295e8975cec4bd22))
|
|
8
|
+
|
|
9
|
+
## [1.46.1](https://github.com/CoCreate-app/CoCreate-cli/compare/v1.46.0...v1.46.1) (2024-01-03)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Bug Fixes
|
|
13
|
+
|
|
14
|
+
* add fs module ([c367f37](https://github.com/CoCreate-app/CoCreate-cli/commit/c367f374ca5ec5ff58c8d050977151b6a3bf3021))
|
|
15
|
+
|
|
1
16
|
# [1.46.0](https://github.com/CoCreate-app/CoCreate-cli/compare/v1.45.3...v1.46.0) (2023-12-31)
|
|
2
17
|
|
|
3
18
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/cli",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.47.0",
|
|
4
4
|
"description": "Polyrepo management bash CLI tool. Run all git commands and yarn commands on multiple repositories. Also includes a few custom macros for cloning, installing, etc.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cli",
|
|
@@ -55,10 +55,10 @@
|
|
|
55
55
|
"coc": "src/coc.js"
|
|
56
56
|
},
|
|
57
57
|
"dependencies": {
|
|
58
|
-
"@cocreate/acme": "^1.
|
|
59
|
-
"@cocreate/config": "^1.
|
|
58
|
+
"@cocreate/acme": "^1.1.3",
|
|
59
|
+
"@cocreate/config": "^1.10.0",
|
|
60
60
|
"@cocreate/file": "^1.13.0",
|
|
61
|
-
"@cocreate/nginx": "^1.
|
|
61
|
+
"@cocreate/nginx": "^1.2.0",
|
|
62
62
|
"glob": "^7.1.7",
|
|
63
63
|
"prettier": "^2.3.2"
|
|
64
64
|
}
|
package/src/commands/link.js
CHANGED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
const { exec } = require("child_process");
|
|
2
|
+
|
|
3
|
+
// Define the commands
|
|
4
|
+
const commands = [
|
|
5
|
+
"sudo apt-get update",
|
|
6
|
+
"sudo apt-get install -y nfs-common",
|
|
7
|
+
`sudo mkdir /mnt/efs`,
|
|
8
|
+
// Replace fs-12345678 with your actual file system ID and us-west-2 with your EFS region
|
|
9
|
+
"sudo mount -t nfs4 -o nfsvers=4.1,rsize=1048576,wsize=1048576,hard,timeo=600,retrans=2 fs-060287caeafac2302.efs.us-east-1.amazonaws.com:/ /mnt/efs"
|
|
10
|
+
];
|
|
11
|
+
|
|
12
|
+
// Function to execute each command
|
|
13
|
+
const executeCommand = (command) => {
|
|
14
|
+
return new Promise((resolve, reject) => {
|
|
15
|
+
exec(command, (error, stdout, stderr) => {
|
|
16
|
+
if (error) {
|
|
17
|
+
console.warn(error);
|
|
18
|
+
reject();
|
|
19
|
+
}
|
|
20
|
+
console.log(stdout);
|
|
21
|
+
resolve();
|
|
22
|
+
});
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
// Execute all commands in sequence
|
|
27
|
+
const runCommands = async () => {
|
|
28
|
+
for (const command of commands) {
|
|
29
|
+
console.log(`Running: ${command}`);
|
|
30
|
+
try {
|
|
31
|
+
await executeCommand(command);
|
|
32
|
+
} catch (error) {
|
|
33
|
+
console.error(`Error executing ${command}`);
|
|
34
|
+
break; // Exit if any command fails
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
console.log("All commands executed successfully.");
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
runCommands();
|