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

Add MergeBytes to merge raw FCCs into raw Ignition #120

Closed
wants to merge 1 commit into from
Closed

Add MergeBytes to merge raw FCCs into raw Ignition #120

wants to merge 1 commit into from

Conversation

dghubble
Copy link
Member

@dghubble dghubble commented Jul 21, 2020

  • Add MergeBytes functions to v1_X subpackages to perform Translation and Ignition Merge of fragments at a specific Ignition version
  • Add getMerger to determine the right merger function to call based on the first fragment's variant and version
  • Add MergeBytes to wrap actual merger function uses

TODO: Not yet verified / used
Related: #118

* Add MergeBytes functions to v1_X subpackages to perform
Translation and Ignition Merge of fragments at a specific
Ignition version
* Add getMerger to determine the right merger function
to call based on the first fragment's variant and version
* Add MergeBytes to wrap actual merger function uses
@dghubble dghubble changed the title Explore some ways of merging configs Add MergeBytes to merge raw FCCs into raw Ignition Jul 21, 2020
@dghubble dghubble marked this pull request as ready for review July 21, 2020 07:49
// MergeBytes translates and merges a slice of raw configs to a single raw
// Ignition config. The variant and version of the first raw config
// ("fragment") determines the merger version to use.
func MergeBytes(fragments [][]byte, options common.TranslateOptions) ([]byte, error) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is report merging a thing?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, there is Report.Merge() for that.

@dghubble
Copy link
Member Author

I haven't forgotten this, but probably will return to it next week

@dghubble
Copy link
Member Author

Need to refresh this. Handling merging external to fcct is getting painful.

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.

2 participants