4

I have a script in my package.json (I am on Win10)

"build-win32": "electron-packager . --electron-version 1.4.15 --platform win32 --icon ./assets/icon.ico --out ./dist --overwrite"

In command prompt I type

npm run build-win32

I get the error: Error: EPERM: operation not permitted, rmdir ...

So the obvious thing to do (to me ) is close command prompt and restart by right clicking and running as admin. I then type in the admin command prompt

npm cache clean

I turn off the admin command prompt and restart a normal command prompt. I try running npm run build-win32 again, but get the same error.

How can I get this working. I have tried npm cache clean in a non-admin command prompt as well.

Rewind
  • 2,554
  • 3
  • 30
  • 56
  • Check that there is no node process left that could have locked the files. You are not using Atom as IDE ? Sometimes it has exclusive locks. – Janne Feb 18 '17 at 18:21
  • I am not sure what this means. I have VS running in the background so I can edit the files. – Rewind Feb 18 '17 at 18:39
  • Try closing VS and run build again. Also check from task manager that no left over node processes are hanging there. – Janne Feb 18 '17 at 18:48
  • 1
    Thanks for the ideas. I have tried everything you have suggested, but sadly they do not work. I shut off VS and the command prompt and then just started the command prompt and tried the build again, but it did not work. I also tried running admin and cleaning, but again it did not work. I have checked the Task Manager and there was nothing showing up there. Thank for the ideas though. – Rewind Feb 18 '17 at 19:39

0 Answers0