-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
If a group group-name is defined in two different files, the group members won't be combined into a single group definition. This will throw an error:
duplicate name "group:group-name" in object (lines X:Y and Z:Y)
I believe it is expected that a combiner does the following if a group name is encountered multiple times:
- Collect all members from each occurrence
- Merge them into a single group definition (deduplicating members, if needed)
- Then, include the group in the final combined output
Groups with the same name defined across multiple files should have their members merged into a single group definition in the combined output. Merging groups would enable much more flexible organizational structures in child files.
Example
companies/company-1/groups.hujson:
{
"groups": {
"group:group-name": [
"member-1@company.com",
"member-2@company.com",
]
}
}
companies/company-2/groups.hujson:
{
"groups": {
"group:group-name": [
"member-3@company.com",
"member-4@company.com",
]
}
}
Expected combined output:
{
"groups": {
// from `companies/company-1/groups.hujson`
// and `companies/company-2/groups.hujson`
"group:group-name": [
"member-1@company.com",
"member-2@company.com",
"member-3@company.com",
"member-4@company.com",
]
}
}
Current output:
{
"groups": {
// from `companies/company-1/groups.hujson`
"group:group-name": ["member-1@company.com", "member-2@company.com"],
// from `companies/company-2/groups.hujson`
"group:group-name": ["member-3@company.com", "member-4@company.com"],
}
}
Metadata
Metadata
Assignees
Labels
No labels