Sira_PS
(Sira PS)
1
I have a Hash which value is Array of Hashes. And I expected to generate
the yaml like this:
···
---
Session:
singular: Session
email: Email
password: Password
rememberMe: Remember Me!
But when I use dump method to generate yaml file and the result is:
---
- Session:
- singular: |
Session
- email: |
Email
- password: |
Password
- rememberMe: |
Remember Me!
When I print out my hash on command line, it look like this:
SessionsingularSession
emailEmail
passwordPassword
rememberMeRemember Me!
What do you think? Am I wrong with any steps?
If I need to generate yaml look like above, how can I do?
--
Posted via http://www.ruby-forum.com/.
Can you provide the code you're using to produce this YAML?
···
On Fri, Apr 22, 2011 at 02:23:19PM +0900, Siratinee Sukachai wrote:
I have a Hash which value is Array of Hashes. And I expected to generate
the yaml like this:
---
Session:
singular: Session
email: Email
password: Password
rememberMe: Remember Me!
But when I use dump method to generate yaml file and the result is:
---
- Session:
- singular: |
Session
- email: |
Email
- password: |
Password
- rememberMe: |
Remember Me!
When I print out my hash on command line, it look like this:
SessionsingularSession
emailEmail
passwordPassword
rememberMeRemember Me!
What do you think? Am I wrong with any steps?
If I need to generate yaml look like above, how can I do?
--
Aaron Patterson
http://tenderlovemaking.com/