Problemas ao instalar o ionic


#1

npm WARN ionic-project@1.1.1 No repository field.
npm WARN ionic-project@1.1.1 No license field.

Adding initial native plugins
shell.js: internal error
Error: EBUSY: resource busy or locked, open 'C:\Users\RICHAR~1\AppData\Local\Temp\shelljs_6e881a67ab6a2fd1d6f4’
at Error (native)
at Object.fs.openSync (fs.js:640:18)
at Object.fs.writeFileSync (fs.js:1333:33)
at execSync (C:\Users\RICHARD RODRIGUES\AppData\Roaming\npm\node_modules\ionic\node_modules\shelljs\src\exec.js:67:57)
at Object._exec (C:\Users\RICHARD RODRIGUES\AppData\Roaming\npm\node_modules\ionic\node_modules\shelljs\src\exec.js:179:12)
at Object.exec (C:\Users\RICHARD RODRIGUES\AppData\Roaming\npm\node_modules\ionic\node_modules\shelljs\src\common.js:168:23)
at Object.getCordovaInfo (C:\Users\RICHARD RODRIGUES\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\lib\info.js:49:24)
at Object.cordovaInstalled (C:\Users\RICHARD RODRIGUES\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\lib\utils.js:318:8)
at Object.Start.initCordova (C:\Users\RICHARD RODRIGUES\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\lib\start.js:750:16)
at C:\Users\RICHARD RODRIGUES\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\lib\start.js:112:20


#2

Try running shell as administrator. If this is not possible, try this:

So what worked for me was deleting all directories on C:\Users\USERNAME\AppData\Local\Temp\ that start with npm-.

Source: https://github.com/npm/npm/issues/13461