open-wc / create

Repository for `npm init @open-wc`
22 stars 24 forks source link

Space in dir breaking on Windows #17

Open MendyBerger opened 3 years ago

MendyBerger commented 3 years ago

When running npm init @open-wc on Windows I get the following error:

Error: EPERM: operation not permitted, mkdir 'C:\Users\Mendy'
command not found: create

I tried to reinstall @open-wc/create already but no luck

I think that it has to do with the space in the directory name C:\Users\Mendy Berger\Documents\whatever

LarsDenBakker commented 3 years ago

We've had reports about this before, but wasn't able to reproduce reliably. This is a good clue, need to look into it more.

depyronick commented 3 years ago

yeah, i can confirm that.

while trying to run command npm init @open-wc it just gave me the exact error that mendy has encountered. then i opened the terminal in administration mode, but it gave the ENOLOCAL error with a trimmed path just where the space is. because it was trying to write to npm cache. then i moved npm cache with npm config set cache C:\npm-cache --global now it works.