有人用 grunt 么?错误求助: ERROR: f2d_register_rpc() => (null) (-21)

2015-03-26 18:26:27 +08:00
 ZZZero
有人用node和grunt么?求助:用grunt的时候出现了这个问题。
2015-03-26 16:15 grunt[5684] (FSEvents.framework) FSEventStreamStart: register_with_server: ERROR: f2d_register_rpc() => (null) (-21)


module.exports = function (grunt) {
//配置模块参数
grunt.initConfig({
cssmin: {
minify: {
expand: true,
cwd: "/",
src: ["**/*.css","**/!*.min.css"],
dest: "/",
ext: ".min.css"
}
},
jshint: {
options: {
trailing: true
},
files: ["**/*.js"]
},
uglify: {
options: {
sourceMap: true
},
target : {
expand: true,
cwd: 'js/origin',
src : '*.js',
dest : '/'
}
},
watch: {
scripts: {
files: "**/*.js",
tasks: ["jshint","uglify"]
},
css: {
files: "**/*.css",
tasks: ["cssmin"]
}
}
});

require("load-grunt-tasks")(grunt);

grunt.registerTask("default",["watch"]);
};
4876 次点击
所在节点    Node.js
8 条回复
learnshare
2015-03-26 18:34:40 +08:00
把你的 node/npm 版本和 package.json 贴一下
FrankFang128
2015-03-26 18:36:09 +08:00
早日改gulp/make吧,祝你好运。
learnshare
2015-03-26 18:39:25 +08:00
@FrankFang128 Gulp 的确不错
ZZZero
2015-03-26 18:42:31 +08:00
@learnshare
npm -v
1.4.28

node -v
v0.10.32

{
"name": "ZZZero-git",
"version": "1.0.0",
"description": "",
"main": "",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"devDependencies": {
"grunt": "^0.4.5",
"grunt-contrib-cssmin": "^0.12.2",
"grunt-contrib-jshint": "^0.11.1",
"grunt-contrib-uglify": "^0.8.0",
"grunt-contrib-watch": "^0.6.1",
"grunt-htmlhint": "^0.4.1",
"load-grunt-tasks": "^3.1.0"
}
}


万分感谢
ZZZero
2015-03-26 18:43:23 +08:00
@FrankFang128 额 grunt不好用么…… 现在貌似用grunt挺多的我就来折腾一下
FrankFang128
2015-03-26 18:53:14 +08:00
@ZZZero 好用,但是比 gulp 慢很多
learnshare
2015-03-26 18:57:45 +08:00
@ZZZero 我没找到什么可以定位错误的东西

https://github.com/gruntjs/grunt-contrib-watch/issues/75 来看,貌似是很久之前的 Bug 了
不过从 https://github.com/joyent/node/issues/5463 来看,好像仍然未修复/发布修复
ZZZero
2015-03-26 19:35:25 +08:00
@learnshare 谢谢 thx!

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/179553

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX