Skip to content
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

A string value surrounded by double quotes, are inconsistent. #25

Open
nmarshall23 opened this issue Oct 18, 2013 · 1 comment
Open
Labels

Comments

@nmarshall23
Copy link

Let me demonstrate.

import org.streum.configrity._
val config = Configuration()
val config2 = config.set("foo",""""bar bar"""")
config2.save("foo.conf")
val config3 = Configuration.load("foo.conf")

val res1 = config2[String]("foo")
val res2 = config3[String]("foo")

Results in res1 equaling "bar bar". However res2 equals bar bar, that is a string that doesn't contain double quotes. What is happening is that while loading Configrity strips off the double quotes.

I think that to be consistent Configrity should keep the double quotes.

@paradigmatic
Copy link
Owner

Yes, I should rewrite the basic formats to be more precise about quotation rules (see issue #24 for instance). The problem is that I won't have much time until november, and that I am not a parser/regex specialist. So unfortunately I won't be able to fix this problem next week without help...

nmarshall23 added a commit to nmarshall23/Configrity that referenced this issue Oct 21, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants