pinme 2.0.6-beta.1 → 2.0.6-beta.2
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 +11 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -5978,7 +5978,7 @@ var import_chalk26 = __toESM(require("chalk"));
|
|
|
5978
5978
|
var import_figlet5 = __toESM(require("figlet"));
|
|
5979
5979
|
|
|
5980
5980
|
// package.json
|
|
5981
|
-
var version = "2.0.6-beta.
|
|
5981
|
+
var version = "2.0.6-beta.2";
|
|
5982
5982
|
|
|
5983
5983
|
// bin/upload.ts
|
|
5984
5984
|
var import_path7 = __toESM(require("path"));
|
|
@@ -7422,10 +7422,20 @@ function findPinmeConfig(startPath) {
|
|
|
7422
7422
|
return void 0;
|
|
7423
7423
|
}
|
|
7424
7424
|
}
|
|
7425
|
+
function shouldInferProjectNameFromUploadPath(targetPath) {
|
|
7426
|
+
try {
|
|
7427
|
+
return import_fs3.default.statSync(targetPath).isDirectory() && import_path7.default.basename(targetPath) === "dist";
|
|
7428
|
+
} catch {
|
|
7429
|
+
return false;
|
|
7430
|
+
}
|
|
7431
|
+
}
|
|
7425
7432
|
function resolveUploadProjectName(targetPath) {
|
|
7426
7433
|
if (APP_CONFIG.pinmeProjectName) {
|
|
7427
7434
|
return APP_CONFIG.pinmeProjectName;
|
|
7428
7435
|
}
|
|
7436
|
+
if (!shouldInferProjectNameFromUploadPath(targetPath)) {
|
|
7437
|
+
return void 0;
|
|
7438
|
+
}
|
|
7429
7439
|
const configPaths = [
|
|
7430
7440
|
findPinmeConfig(targetPath),
|
|
7431
7441
|
findPinmeConfig(process.cwd())
|