8000 Normalize policy JSON before diffing by mbarbon · Pull Request #4 · uber/astro · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Normalize policy JSON before diffing #4

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

mbarbon
Copy link
Contributor
@mbarbon mbarbon commented Sep 28, 2018

Currently, Astro uses Indent(), which only changes whitespace:
Unmarshal+Marshal is necessary for keys to be sorted.

To avoid confusion, the case when old and new policies are the same
after normalization still shows the field as modified with an explanatory
message, and there is a command-line switch to disable policy diffing.

Indent() only changes whitespace, Unmarshal+Marshal is necessary
for keys to be sorted.
- display the field name before the diff
- special-case the case when there is no difference
  (for example another attribute change is forcing an object recreation)
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

Successfully merging this pull request may close these issues.

1 participant
0