코로 넘어져도 헤딩만 하면 그만

npm ERR! code ENOENT 본문

CODE STATES 44

npm ERR! code ENOENT

꼬드리 2023. 6. 2. 15:09

npm install를 하려다가 다음과 같은 에러와 마주쳤다. 

다른 문구보다 no such file or directory가 눈에 띈다. 

npm ERR! code ENOENT
npm ERR! syscall open
npm ERR! path /home/user/coding-files/fe-sprint-practice-deploy/package.json
npm ERR! errno -2
npm ERR! enoent ENOENT: no such file or directory, open '/home/user/coding-files/fe-sprint-practice-deploy/package.json'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! A complete log of this run can be found in:

 

혹시나 해서 검색해 본 결과, package.json파일이 있는 폴더가 아니라 상위 폴더에서 npm install을 해주려고 한 것이 문제가 된 듯하다. 폴더 내부로 이동한 뒤 깔아주니 에러 없이 무사히 완료되었다.

언제나 폴더를 잘 선택했는지 확인할 것!

'CODE STATES 44' 카테고리의 다른 글

CORS에러와 프록시  (0) 2023.06.07
CI/CD 및 github action의 workflow  (0) 2023.06.05
Typescript 맛봄 (2)  (0) 2023.05.31
"Cannot read properties of undefined (reading 'pathname')" 에러  (0) 2023.05.31
Typescript 맛봄 (1)  (0) 2023.05.30
Comments