bitfab-cli 0.2.172 → 0.2.174
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 +13 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -8816,7 +8816,8 @@ var require_dist = __commonJS({
|
|
|
8816
8816
|
});
|
|
8817
8817
|
|
|
8818
8818
|
// src/index.ts
|
|
8819
|
-
import {
|
|
8819
|
+
import { realpathSync } from "fs";
|
|
8820
|
+
import { fileURLToPath as fileURLToPath5 } from "url";
|
|
8820
8821
|
import { cancel as cancel2 } from "@clack/prompts";
|
|
8821
8822
|
|
|
8822
8823
|
// src/init.ts
|
|
@@ -32091,11 +32092,17 @@ ${GLOBAL_HELP_TEXT}`);
|
|
|
32091
32092
|
abortUpdateCheck();
|
|
32092
32093
|
process.exit(1);
|
|
32093
32094
|
}
|
|
32094
|
-
function
|
|
32095
|
-
|
|
32096
|
-
|
|
32095
|
+
function isEntrypoint(entrypoint, moduleUrl) {
|
|
32096
|
+
if (entrypoint === void 0) {
|
|
32097
|
+
return false;
|
|
32098
|
+
}
|
|
32099
|
+
try {
|
|
32100
|
+
return realpathSync(entrypoint) === realpathSync(fileURLToPath5(moduleUrl));
|
|
32101
|
+
} catch {
|
|
32102
|
+
return false;
|
|
32103
|
+
}
|
|
32097
32104
|
}
|
|
32098
|
-
if (
|
|
32105
|
+
if (isEntrypoint(process.argv[1], import.meta.url)) {
|
|
32099
32106
|
main().catch((err) => {
|
|
32100
32107
|
const message = err instanceof Error ? err.message : String(err);
|
|
32101
32108
|
cancel2(message);
|
|
@@ -32105,6 +32112,7 @@ if (isDirectRun()) {
|
|
|
32105
32112
|
export {
|
|
32106
32113
|
getHelpText,
|
|
32107
32114
|
getHelpTopic,
|
|
32115
|
+
isEntrypoint,
|
|
32108
32116
|
parseArgs2 as parseArgs,
|
|
32109
32117
|
wantsHelp
|
|
32110
32118
|
};
|