You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to make vitepress (with a package.json) build with Deno using:
DENO_FUTURE=1 deno i --allow-scripts
deno task build
It results in this error:
Error launching 'node': No such file or directory (os error 2)
error: script 'postinstall' in '[email protected]' failed with exit code 1
Cleaning up project directory and file based variables
00:01
ERROR: Job failed: exit code 1
The problem is that node is used as an executable inside of the postinstall script of the package:
I submitted an MR to vue-demi to skip the postinstall script if node is not found, because it not essential: vueuse/vue-demi#266
I'm not sure if that's the solution, or if we want to make it use the deno executable there. It would improve compatibility.
I was also able to work around it by using --allow-scripts=npm:esbuild to whitelist the only other package with a postinstall script, but it would be frustrating if there was a lot of other packages and no way to blacklist
The text was updated successfully, but these errors were encountered:
I'm not sure if that's the solution, or if we want to make it use the deno executable there. It would improve compatibility.
Yeah this should use the deno executable. We actually do this already, it just currently falls back to node if there are flags specified. (In other words, node postinstall.js already works and runs Deno). We just need to handle the -e / —eval flag.
It’s straightforward, the only complication is that we should wrap the eval-ed code to inject a require function (and potentially node globals, though they aren’t strictly required in this particular case).
Version: Deno 1.45.5
I am trying to make vitepress (with a package.json) build with Deno using:
It results in this error:
The problem is that
node
is used as an executable inside of the postinstall script of the package:I submitted an MR to vue-demi to skip the postinstall script if node is not found, because it not essential: vueuse/vue-demi#266
I'm not sure if that's the solution, or if we want to make it use the
deno
executable there. It would improve compatibility.I was also able to work around it by using
--allow-scripts=npm:esbuild
to whitelist the only other package with a postinstall script, but it would be frustrating if there was a lot of other packages and no way to blacklistThe text was updated successfully, but these errors were encountered: