@magnetoagents/cli 0.1.0 → 0.1.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/cli.js +4 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -658,7 +658,10 @@ function isEntrypoint() {
|
|
|
658
658
|
if (!invoked)
|
|
659
659
|
return false;
|
|
660
660
|
try {
|
|
661
|
-
|
|
661
|
+
// npm installs bins as SYMLINKS (node_modules/.bin/magneto → dist/cli.js);
|
|
662
|
+
// path.resolve() does not follow them, so realpath both sides or the CLI
|
|
663
|
+
// silently no-ops on every installed invocation (0.1.0 regression).
|
|
664
|
+
return fs.realpathSync(invoked) === fs.realpathSync(fileURLToPath(import.meta.url));
|
|
662
665
|
}
|
|
663
666
|
catch {
|
|
664
667
|
return false;
|