Skip to content

scandio/label-merge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

LabelMerge

Utility class to merge two sets of labels.

Example:

Set<String> baseLabels = new LinkedHashSet<String>() {{
    add("1"); add("2"); add("3"); // base labels, i.e. the set of labels when the branch was created
}};

Set<String> leftLabels = new LinkedHashSet<String>() {{
    add("1"); add("2"); // left side removes label "3"
}};

Set<String> rightLabels = new LinkedHashSet<String>() {{
    add("1"); add("2"); add("3"); add("4"); // right side adds label "4"
}};

LabelMerge.mergeLabels(baseLabels, leftLabels, rightLabels); // returns 1, 2, 4

About

Utility class to merge two sets of labels

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages