나는 구축을 위해 노력하고있어 GitHub의에 JQuery와 - UI 라이브러리 사용을 grunt
하지만, 실행 한 후 npm install
나는 여전히에 따라 명령을 실행할 수 없습니다 readme 파일 . 그것은 단지 제공합니다 No command 'grunt' found
:
james@ubuntu:~/Documents/projects/ad2/lib/jquery-ui$ grunt build
No command 'grunt' found, did you mean:
Command 'grun' from package 'grun' (universe)
grunt: command not found
james@ubuntu:~/Documents/projects/ad2/lib/jquery-ui$ npm ls
[email protected] /home/james/Documents/projects/ad2/lib/jquery-ui
├─┬ [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ ├─┬ [email protected]
│ │ ├── [email protected]
│ │ ├── [email protected]
│ │ └── [email protected]
│ ├── [email protected]
│ ├─┬ [email protected]
│ │ └─┬ [email protected]
│ │ └── [email protected]
│ ├─┬ [email protected]
│ │ ├── [email protected]
│ │ └── [email protected]
│ ├── [email protected]
│ ├─┬ [email protected]
│ │ ├── [email protected]
│ │ └─┬ [email protected]
│ │ └── [email protected]
│ ├─┬ [email protected]
│ │ ├── [email protected]
│ │ └─┬ [email protected]
│ │ ├── [email protected]
│ │ ├── [email protected]
│ │ └── [email protected]
│ ├─┬ [email protected]
│ │ └── [email protected]
│ ├─┬ [email protected]
│ │ ├── [email protected]
│ │ └─┬ [email protected]
│ │ ├── [email protected]
│ │ ├─┬ [email protected]
│ │ │ └── [email protected]
│ │ └── [email protected]
│ ├── [email protected]
│ ├─┬ [email protected]
│ │ └── [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ └── [email protected]
├── [email protected]
├─┬ [email protected]
│ ├── [email protected]
│ └── [email protected]
├── [email protected]
├── [email protected]
├─┬ [email protected]
│ └── [email protected]
└─┬ [email protected]
└── [email protected]
난 헷갈려, 내가 뭘 놓치고 있니?
명령 줄 도구는 최신 버전의 Grunt (작성 당시 0.4)에 포함되어 있지 않고 별도로 설치해야합니다.
이것은 다른 프로젝트에서 다른 버전의 Grunt grunt
를 실행할 수 있지만 여전히 간결한 명령을 사용하여 실행할 수 있음을 의미하기 때문에 좋은 생각 입니다.
따라서 먼저 grunt cli 도구를 전역 적으로 설치하십시오.
npm install -g grunt-cli
(또는 가능 sudo npm install -g grunt-cli
).
다음을 입력하여 작동하는지 확인할 수 있습니다. grunt --version
이제 현재 버전의 Grunt를 프로젝트에 로컬로 설치할 수 있습니다. 따라서 프로젝트 위치에서 ...
npm install grunt --save-dev
save-dev
스위치는 꼭 필요한 것은 있지만 개발에만 모듈로의 package.json의 devDependencies 섹션에서 꿀꿀을 표시하기 때문에 좋은 아이디어이다.
이 기사는 인터넷에서 수집됩니다. 재 인쇄 할 때 출처를 알려주십시오.
침해가 발생한 경우 연락 주시기 바랍니다[email protected] 삭제
몇 마디 만하겠습니다