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

Fix ordering of overlays and overlay vars in Relx #1610

Merged
merged 1 commit into from
Aug 16, 2017

Conversation

ferd
Copy link
Collaborator

@ferd ferd commented Aug 15, 2017

Specifically, this impacts profiles. It appears that relx as a whole
requires its configuration to be merged in one tuple order (New takes
precedence over Old), whereas the overlays require the opposite (Old
takes precedence over New) since the operation order on disk is
important to work well.

This patch reorders overlay values such that the overlay of a profile
takes place after the basic overlay, ensuring that the profile actions
take place after the basic ones; this allows profiles to properly
overwrite files as expected (see #1609)

This is done while adequately maintaining the order of operations that
were required as part of #1563

Overlay vars of profiles are also checked to be working fine, along with
a test.

This fixes #1247 and #1609

Specifically, this impacts profiles. It appears that relx as a whole
requires its configuration to be merged in one tuple order (New takes
precedence over Old), whereas the overlays require the opposite (Old
takes precedence over New) since the operation order on disk is
important to work well.

This patch reorders overlay values such that the overlay of a profile
takes place *after* the basic overlay, ensuring that the profile actions
take place after the basic ones; this allows profiles to properly
overwrite files as expected (see erlang#1609)

This is done while adequately maintaining the order of operations that
were required as part of erlang#1563

Overlay vars of profiles are also checked to be working fine, along with
a test.

This fixes erlang#1247 and erlang#1609
@ferd ferd mentioned this pull request Aug 15, 2017
@halturin
Copy link

Perfect! Now it works as I expected! Thanx!

@ferd ferd merged commit 3d15c00 into erlang:master Aug 16, 2017
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.

overlay_vars in a profile is not used
3 participants