@saidulbadhon/jssm-cli 1.8.3 → 1.9.1
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/dist/index.js +18 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4189,7 +4189,9 @@ async function pullEnvFile(host, apiKey, project, filename = ".env") {
|
|
|
4189
4189
|
async function listEnvFiles(host, apiKey, project) {
|
|
4190
4190
|
const url = `${host}/projects/${encodeURIComponent(project)}/files/list`;
|
|
4191
4191
|
const data = await apiRequest(url, apiKey);
|
|
4192
|
-
return data.files
|
|
4192
|
+
return data.files.map(
|
|
4193
|
+
(file) => typeof file === "string" ? file : file.filename
|
|
4194
|
+
);
|
|
4193
4195
|
}
|
|
4194
4196
|
|
|
4195
4197
|
// src/utils/repoDetector.ts
|
|
@@ -4642,7 +4644,13 @@ async function pullCommand2(args2) {
|
|
|
4642
4644
|
);
|
|
4643
4645
|
const dir = dirname(outputPath);
|
|
4644
4646
|
if (dir !== process.cwd()) {
|
|
4645
|
-
|
|
4647
|
+
try {
|
|
4648
|
+
await mkdir3(dir, { recursive: true });
|
|
4649
|
+
} catch (mkdirError) {
|
|
4650
|
+
if (!(mkdirError instanceof Error) || !("code" in mkdirError) || mkdirError.code !== "EEXIST") {
|
|
4651
|
+
throw mkdirError;
|
|
4652
|
+
}
|
|
4653
|
+
}
|
|
4646
4654
|
}
|
|
4647
4655
|
await writeFile3(outputPath, content, "utf-8");
|
|
4648
4656
|
const varCount = countVariables(content);
|
|
@@ -4776,7 +4784,13 @@ async function pullCommand2(args2) {
|
|
|
4776
4784
|
);
|
|
4777
4785
|
const dir = dirname(outputPath);
|
|
4778
4786
|
if (dir !== process.cwd()) {
|
|
4779
|
-
|
|
4787
|
+
try {
|
|
4788
|
+
await mkdir3(dir, { recursive: true });
|
|
4789
|
+
} catch (mkdirError) {
|
|
4790
|
+
if (!(mkdirError instanceof Error) || !("code" in mkdirError) || mkdirError.code !== "EEXIST") {
|
|
4791
|
+
throw mkdirError;
|
|
4792
|
+
}
|
|
4793
|
+
}
|
|
4780
4794
|
}
|
|
4781
4795
|
await writeFile3(outputPath, content, "utf-8");
|
|
4782
4796
|
const varCount = countVariables(content);
|
|
@@ -5948,7 +5962,7 @@ ${import_chalk.default.bold("Usage in Docker:")}
|
|
|
5948
5962
|
|
|
5949
5963
|
// src/utils/versionCheck.ts
|
|
5950
5964
|
var PACKAGE_NAME = "@saidulbadhon/jssm-cli";
|
|
5951
|
-
var CURRENT_VERSION = "1.
|
|
5965
|
+
var CURRENT_VERSION = "1.9.1";
|
|
5952
5966
|
async function getLatestVersion() {
|
|
5953
5967
|
try {
|
|
5954
5968
|
const response = await fetch(`https://registry.npmjs.org/${PACKAGE_NAME}`);
|