Re: Literal for plain style string
"Clark C. Evans" <[email protected]>
| Newsgroups | gmane.text.yaml.general |
|---|---|
| Message-ID | <[email protected]> |
As much as this is a good idea, I'm afrid it'd be very hard to just make this change -- it would require a directive at the very minimum. On Wed, Aug 08, 2007 at 02:44:01PM -0700, TRANS wrote: | I would like to make a repeated proposal that a future version of YAML | make the plan style string literal vs. the current folding. | | I suggested this before b/c it better suited using YAML as a means of | storing programming code b/c many programming languages use a new line | to indicate the end of a statement. The repetitive use of '|' was | unsightly and easy to forget. | | Now I have discovered another use. I use YAML for configuration files | as much as possible. But a simple line by line list is generally too | convenient to replace with YAML. However if the default string style | were literal, then such a file would already be vaild YAML (I make an | exception for the mandatory %YAML directive b/c implementations tend | not to enforce this.) In other words a file that looked like: | | some/file/path1 | some/file/path2 | some/file/path3 | | could be loaded by YAML and would look just as the original file | appears. Currently, the specification causes all these lines to merge | into one line which, obviously, makes the entries ambiguous and | useless. That's a really good point. Best, Clark ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/