我习惯用这样的东西
npm install grunt-contrib-jshint --save-dev用于安装。
然而,这一做法并没有奏效:
npm install grunt-contrib-phplint --save-dev我在这里发现了这些地点:
https://www.npmjs.com/package/phplint
https://github.com/jgable/grunt-phplint
但是它看起来与我的代码的其余部分不匹配。当然,我需要安装它并修改Gruntfile.js。
// you must load each module
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-qunit');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-cssmin');
// grunt.loadNpmTasks("grunt-phplint"); // from links发布于 2016-04-04 04:41:18
奇怪的是,这个特定的包没有使用cont肋骨前缀。
只需用于安装:
npm install grunt-phplint --save-dev;这个来加载任务:
grunt.loadNpmTasks("grunt-phplint");最后,运行该任务:
phplint: {
good: [your_php_dir + "*.php"]
},https://stackoverflow.com/questions/36394224
复制相似问题