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
Rewrite rename #3841
Rewrite rename #3841
Conversation
+1 for the positional version :) A general confusion already exists when using name-value pairs, due to the I'm not sure which version would be more intuitive for our users, but for me, |
Build SUCCESS |
6d28020
to
f91331c
Compare
Build SUCCESS |
f91331c
to
9465b99
Compare
Build SUCCESS |
9465b99
to
fb91d36
Compare
Build SUCCESS |
Copies source() value into the destination(), and removes the source() nv entry. If source() == destination() this means do nothing. If the source() points to a not existing nv entry, also does nothing. ``` rewrite { rename( source("from") destination("to") ); } ``` Signed-off-by: Kokan <kokaipeter@gmail.com>
Signed-off-by: Kokan <kokaipeter@gmail.com>
Signed-off-by: Kokan <kokaipeter@gmail.com>
Instead of providing source/destination options, simply use the first string as source and the second string as destination. ``` rewrite { rename("old_key" "new_key") }; ``` Signed-off-by: Kokan <kokaipeter@gmail.com>
Resolved conflict. |
fb91d36
to
d3af25a
Compare
Build SUCCESS |
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.
Cool :)
Signed-off-by: Gabor Nagy <gabor.nagy@oneidentity.com>
news: correct PR number for #3841
This is a native implementation of #3814. The interface has been tweaked a little with using positional options.
In the following cases the
rename()
does not changes the message:source()
equals todestination()
source()
entry not present in the message