gruntjs / gruntjs/grunt

All Tasks should have output formatting consistency

Open
#697 4 comments 0 reactions 0 assignees View on GitHub
needs discussion
Dominant language
JavaScript
Stars
12.2k
Forks
1.5k
PR merge metrics
No merged PRs in 30d

Description

I have a proposal for `grunt` and the family of `grunt-contrib-*` plugins. (and even beyond to 3rd-party plugins) When running tasks, there's no agreed-upon standard for outputting log data. For example, destination/output files are output in cyan by the `less` task while `concat` simply wraps the value in quotes and `compass` does nothing. It would be great if at least the official plugins could agree upon a "style guide" for outputting specific bits of data in their output.

In addition, this "style guide" can either be published in documentation for plugin developers to optionally include in their tasks, or perhaps an API of sorts could be exposed as methods on `grunt.log` and friends.

Some examples of what I mean exactly:
- Output task names underlined (already enforced by grunt itself)
- Output destination/output files in cyan (taken from `less`)
- Output source/input files in grey
- Output file sizes in human-friendly format (taken from `compress`) in green

Does anyone else have any thoughts on something like this? I think this could definitely improve the readability of grunt-powered build processes (especially fairly complex/large ones that I currently maintain) and could very well be "low-hanging fruit".

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.