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

Json.lns fail to handle backslashes #557

Closed
Salokyn opened this issue May 23, 2018 · 2 comments
Closed

Json.lns fail to handle backslashes #557

Salokyn opened this issue May 23, 2018 · 2 comments

Comments

@Salokyn
Copy link
Contributor

Salokyn commented May 23, 2018

Hello,
I try to edit the settings.json file from transmission-daemon debian 9 package with augtool 1.8.0 or augeas resource in puppet 4.8.2 and it fails to parse it because of the backslashes in it :

{
    "blocklist-enabled": 0,
    "download-dir": "\/var\/lib\/transmission-daemon\/downloads",
    "download-limit": 100,
    "download-limit-enabled": 0,
    "encryption": 1,
    "max-peers-global": 200,
    "peer-port": 51413,
    "pex-enabled": 1,
    "port-forwarding-enabled": 0,
    "rpc-authentication-required": 1,
    "rpc-password": "transmission",
    "rpc-port": 9091,
    "rpc-username": "transmission",
    "rpc-whitelist": "127.0.0.1",
    "upload-limit": 100,
    "upload-limit-enabled": 0
}

Regards

lutter added a commit to lutter/augeas that referenced this issue May 24, 2018
According to https://www.json.org/, a string like "\/" is legal in Json.

Fixes hercules-team#557
lutter added a commit to lutter/augeas that referenced this issue May 24, 2018
According to https://www.json.org/, a string like "\/" is legal in Json.

Fixes hercules-team#557
lutter added a commit to lutter/augeas that referenced this issue May 24, 2018
According to https://www.json.org/, a string like "\/" is legal in Json.

Fixes hercules-team#557
@lutter
Copy link
Member

lutter commented May 24, 2018

I just posted a PR that solves this for me. Would be great if you could give it a quick spin. I'll probably merge it in a few days.

@Salokyn
Copy link
Contributor Author

Salokyn commented May 25, 2018

Hi,
It works for me.
Thank you.

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

2 participants