Open khalilou88 opened 8 months ago
Im curious how crystal can help with the maven integration. On another note, we could contribute migrators as we currently maintain them ourselves but would be good to put them where they belong?
New design:
{
"mavenRootDirectory": "nx-maven",
"localRepoRelativePath: ".m2/repository",
"buildTargetName": "build-maven",
"testTargetName": "test-maven",
"targets": [
{
"target": "build-maven",
"defaultTask": "install"
},
{
"target": "test-maven",
"defaultTask": "test"
},
{
"target": "ktlint",
"defaultTask": "antrun:run@ktlint"
}
]
}
I like the *TargetName options.
would make targets optional and change defaultTask to task
I already added buildTargetName
to the plugin options: https://github.com/khalilou88/jnxplus/commit/628c80f1f1652e1f7478b3dae37cf8a0a9ce9789
I believe we need more than one task:
{
"target": "build-maven",
"appTask": "compile -DskipTests=true",
"libTask": "install -DskipTests=true",
"defaultTask": "install"
},
{
"mavenRootDirectory": ".",
"localRepoRelativePath: ".m2/repository",
"lintTargetName": "maven-lint",
"formatTargetName": "maven-format",
"testTargetName": "maven-test",
"buildTargetName": "maven-build",
"releaseTargetName": "maven-release",
"e2eTargetName": "maven-e2e"
"targets": [
{
"target": "testTargetName",
"task": "test"
},
{
"target": "buildTargetName",
"task": "clean install -DskipTests=true"
},
{
"target": "releaseTargetName",
"task": "deploy -DskipTests=true"
}
...
]
}
An issue here is that there is allot of rebuilding going on. Would be nice to have something like
I think of adding
targets
to plugin option so ifbuild
andtest
not present in theproject.json
or theproject.json
is not present. This will be added automatically:the customName will be optional.
we should use task from Nx default targets first and if not present we use defaultTask from plugin options.