The operation was rejected by your operating system. npm ERR! It's possible that the file was already in use (by a text editor or antivirus) or that you lack permissions to access it. code example

Example 1: The operation was rejected by your operating system. npm ERR! It is likely you do not have the permissions to access this file as the current user

sudo chown -R $USER /usr/local/lib/node_modules

Example 2: The operation was rejected by your operating system. npm ERR! It is likely you do not have the permissions to access this file as the current user

cd /Users/Marc/Desktop/Dev
rm -rf ./masterclass/node_mdoules/
chown -R $USER ./masterclass/
cd masterclass    
npm install

Tags:

Misc Example