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

Escaped characters don't get properly unescaped #16

Open
nostradani opened this issue Nov 26, 2020 · 0 comments
Open

Escaped characters don't get properly unescaped #16

nostradani opened this issue Nov 26, 2020 · 0 comments

Comments

@nostradani
Copy link

nostradani commented Nov 26, 2020

When java writes a properties file, the following characters get escaped: =:!#

{ "Caution" => "=:!#" } will be written by Java as Caution=\=\:\!\#

In general, Java seems to simply omit single backslashes when parsing a properties file
Example: "Invalid=x\x" will be read as {"Invalid" => "xx" }

However this gem doesn't respect that. When reading the first properties file, it will become {"Caution" => "\=\:\!\#" }
Writing that again, it will become Caution=\\=\\:\\!\\#

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant