Permissions error when using npm

.../Angular-Project/curso-angular $ npm install npm ERR! code EACCES npm ERR! syscall symlink npm ERR! path ../@angular/cli/bin/ng.js npm ERR! dest /storage/emulated/0/Download/Angular-Project/curso-angular/node_modules/.bin/ng npm ERR! errno -13 npm ERR! Error: EACCES: permission denied, symlink '../@angular/cli/bin/ng.js' -> '/storage/emulated/0/Download/Angular-Project/curso-angular/node_modules/.bin/ng' npm ERR! [Error: EACCES: permission denied, symlink '../@angular/cli/bin/ng.js' -> '/storage/emulated/0/Download/Angular-Project/curso-angular/node_modules/.bin/ng'] { npm ERR! errno: -13, npm ERR! code: 'EACCES', npm ERR! syscall: 'symlink', npm ERR! path: '../@angular/cli/bin/ng.js', npm ERR! dest: '/storage/emulated/0/Download/Angular-Project/curso-angular/node_modules/.bin/ng' npm ERR! } npm ERR! npm ERR! 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 npm ERR! npm ERR! If you believe this might be a permissions issue, please double-check the npm ERR! permissions of the file and its containing directories, or try running npm ERR! the command again as root/Administrator. npm ERR! A complete log of this run can be found in: /data/data/com.termux/files/home/.npm/_logs/2024-04-23T12_54_42_464Z-debug-0.log
6 Replies
Catinette
Catinette2mo ago
im not really sure, but i think you have to move the Dwnload/Angular-Project/ folders to internal termux folders not shared folders
Eduardo Augusto
Eduardo Augusto2mo ago
@Catinette Whenever I install a library using npm or npx it gives a permissions error. I've tried using sudo but I don't use root Should I access the /mnt/sdcard directory or the /storage directory?
Catinette
Catinette2mo ago
what no, termux internal folders /data/data/com.termux/files/home or ~/
Eduardo Augusto
Eduardo Augusto2mo ago
Whenever I try to use npm i in a folder other than termux I get a permission error I will send a print
Eduardo Augusto
Eduardo Augusto2mo ago
No description
Catinette
Catinette2mo ago
that's normal you have to do it from termux internal folders