-
Notifications
You must be signed in to change notification settings - Fork 79
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
Add --argjson support #250
Conversation
And hope your having great holidays! |
Very nice PR! Thanks a lot for this, @wader! (Was that some kind of Christmas present? ^^) Anyway, a belated "God Jul" to you as well! |
@@ -134,6 +134,15 @@ fn binds(cli: &Cli) -> Result<Vec<(String, Val)>, Error> { | |||
let s = s.to_owned(); | |||
Ok((k.to_owned(), Val::Str(s.into()))) | |||
}); | |||
let argjson = cli.argjson.iter().map(|(k, s)| { | |||
let s = s.to_owned(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You do not need .to_owned()
here, because parsing does not require an owned string. I removed this call in d268a57.
Yeap! 🎅 same and a gott nytt år to you :) |
Fixes #180