Preferably done after #25.
Ideally, we would remain backwards-compatible and still support such configs:
{
"headerFile": "./license-header.txt",
"style": "SlashStar",
"includes": [
"**/*.go"
],
"excludes": [
"vendor/**/*",
"mocks/**/*"
],
"data": {
"Owner": "Florent Biville (@fbiville)"
}
}
but also allow something like several configuration groups:
{
"groups": [
{
"headerFile": "./license-header-1.txt",
"style": "SlashSlash",
"includes": [
"project_a/**/*.go"
],
"excludes": [
"vendor/**"
],
"data": {
"Company": "Very Important Company",
"Team": "The A-Team of Gophers"
}
},
{
"headerFile": "./license-header-2.txt",
"style": "SlashStar",
"includes": [
"project_b/**/*.scala"
],
"data": {
"Company": "Very Important Company",
"Team": "The B-Team of Scalaists"
}
}
]
}
The use of an object is intended here to make sure future changed are easier to carry out (easier to add attribute to an object than migrate from an array to an object).
Note that if there are files effectively matched by configuration style groups, headache should fail and report the conflicting groups.