按照官网的步骤来安装的:
当创建了已经项目,项目中已经包含了gruntfile.js和packge.json等文件,当时在项目下执行grunt时候出现了下班错误提示,在node_modules中已经存在了grunt和grunt-cli
grunt-cli: The grunt command line interface. (v0.1.9)Fatal error: Unable to find local grunt.If you're seeing this message, either a Gruntfile wasn't found or grunthasn't been installed locally to your project. For more information aboutinstalling and configuring grunt, please see the Getting Started guide
解决方案
问题已经解决,安装配置文件问题。设置为不允许全局安装方式。