Created
April 3, 2013 02:36
-
-
Save colinwren/5298008 to your computer and use it in GitHub Desktop.
Grunt.log.error question
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Desired CoffeeScript compilation Error: | |
| >> SyntaxError: unmatched } | |
| >> In file: main.coffee | |
| >> On line: 15 | |
| >> foo = } bar | |
| >> ^ | |
| The isssue is that grunt.log.error trims whitespace so that | |
| grunt.log.error(' ^') | |
| appears as | |
| >> ^ | |
| instead of | |
| >> ^ | |
| Is there a way to maintain this whitespace without using a non-whitespace character to prevent the trimming? |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Both log.error and log.warn trim the input string. I ended up using grunt.log.writeln (which doesn't trim the string) and added in the red >> to make it look like grunt.log.error