-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Idea: gulp/grunt support #23
Comments
FWIW: For now I'm fixing this with gulp-shell. Then created a task like so:
|
Thanks @bartveneman I think this will be really useful in my CI :) |
Btw, @katiefenn, feel free to close this, as using it with gulp-shell has done the trick for me the last couple of months very, very well. |
For the record, I've made a dedicated gruntplugin for parker. I will add soon the possibility to choose the metrics via the task's options. |
@bartveneman: Thank you for for the tip. I'd still like to write (or contribute to) a dedicated plugin, I'm ticking off the features I want to release to get there. @leny: Brilliant! You might be interested in a couple of features I'm working on in the develop branch. The warnings formatter will output warnings when metric results exceed a configured threshold, which is less verbose than outputting Parker each time the task is run. It'll hopefully be merged into master in the next month or so. |
Looks nice. I will add these features to the grunt plugin when they will be ready. :) |
Maybe nice to add a small update as I didn't really like to run parker with gulp-shell. By installing Parker to the project, I'm able to run it directly from a gulp task: gulp.task("css:report:parker", function () {
var Parker = require("parker"),
metrics = require("parker/metrics/All.js"),
parker = new Parker(metrics),
fs = require("fs");
fs.readFile("path/to/your-css-file.css", "utf8", function (err, data) {
if (err) {
return console.log(err);
}
console.log(parker.run(data));
});
}); Perhaps this is useful for someone else. |
Been working on a gulp version of it. Took some ideas (and code) from @leny to keep things consistent. Still working out different formats, but check it out |
@fnky Thank you! |
Grunt version (from @leny ) don't output as csv or jason. :( |
I'm not really into Node.js, but I'd like to see Parker integrated in my development workflow with Gulp along with CSSLint, Gulp-Sloc etc.
The text was updated successfully, but these errors were encountered: