Description
We enjoy the usage of the lint rule ToolchainVersionRule in our monorepo, as it also informs colleagues on the team what the recommended BTVA version is for a package.
But for some projects in our monorepo we have a custom pom (which has the actual vmware.pscoe pom as parent) to override some behavior to fit our workflow.
When doing this, we lose the lint rules as they are mapped to specific parent artifactId:groupIds
|
static readonly ParentGroupByArtifact = { |
|
"base-package": "com.vmware.pscoe.o11n", |
|
"actions-package": "com.vmware.pscoe.o11n", |
|
"xml-package": "com.vmware.pscoe.o11n", |
|
"typescript-project": "com.vmware.pscoe.o11n", |
|
"typescript-project-all": "com.vmware.pscoe.o11n", |
|
"vra-package": "com.vmware.pscoe.vra", |
|
"vra-ng-package": "com.vmware.pscoe.vra-ng", |
|
"polyglot-project": "com.vmware.pscoe.polyglot" |
|
} |
Would it be possible to add a new extension setting, e.g. vrdev.buildTools.extraVroGroups? Here we could provide an object of key/values, similar to the already existing PomFile.ParentGroupByArtifact.
And then add something like:
static readonly ParentGroupByArtifact = {
"base-package": "com.vmware.pscoe.o11n",
"actions-package": "com.vmware.pscoe.o11n",
"xml-package": "com.vmware.pscoe.o11n",
"typescript-project": "com.vmware.pscoe.o11n",
"typescript-project-all": "com.vmware.pscoe.o11n",
"vra-package": "com.vmware.pscoe.vra",
"vra-ng-package": "com.vmware.pscoe.vra-ng",
"polyglot-project": "com.vmware.pscoe.polyglot",
+ ...vscode.workspace.getConfiguration().get<VrealizeSettings>("vrdev").buildTools.extraVroGroups || {}
}
So the usage would be:
Alternatives
Creating custom lint rules for the XML files. But we'd like to keep it to this extension and ESLint.
Additional Context
I am willing to make a PR for this, but would like the input of the maintainers before starting.
Description
We enjoy the usage of the lint rule
ToolchainVersionRulein our monorepo, as it also informs colleagues on the team what the recommended BTVA version is for a package.But for some projects in our monorepo we have a custom pom (which has the actual
vmware.pscoepom as parent) to override some behavior to fit our workflow.When doing this, we lose the lint rules as they are mapped to specific parent artifactId:groupIds
vrealize-developer-tools/packages/node/vrdt-common/src/maven/PomFile.ts
Lines 10 to 19 in 1cc7b69
Would it be possible to add a new extension setting, e.g.
vrdev.buildTools.extraVroGroups? Here we could provide an object of key/values, similar to the already existingPomFile.ParentGroupByArtifact.And then add something like:
static readonly ParentGroupByArtifact = { "base-package": "com.vmware.pscoe.o11n", "actions-package": "com.vmware.pscoe.o11n", "xml-package": "com.vmware.pscoe.o11n", "typescript-project": "com.vmware.pscoe.o11n", "typescript-project-all": "com.vmware.pscoe.o11n", "vra-package": "com.vmware.pscoe.vra", "vra-ng-package": "com.vmware.pscoe.vra-ng", "polyglot-project": "com.vmware.pscoe.polyglot", + ...vscode.workspace.getConfiguration().get<VrealizeSettings>("vrdev").buildTools.extraVroGroups || {} }So the usage would be:
Alternatives
Creating custom lint rules for the XML files. But we'd like to keep it to this extension and ESLint.
Additional Context
I am willing to make a PR for this, but would like the input of the maintainers before starting.