-
-
Notifications
You must be signed in to change notification settings - Fork 209
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
support context variables at PackageJson and Content Replacer API #9758
support context variables at PackageJson and Content Replacer API #9758
Conversation
...in/java/tech/jhipster/lite/module/infrastructure/secondary/FileSystemPackageJsonHandler.java
Outdated
Show resolved
Hide resolved
src/main/java/tech/jhipster/lite/module/domain/JHipsterModulesApplyer.java
Outdated
Show resolved
Hide resolved
src/main/java/tech/jhipster/lite/module/domain/packagejson/JHipsterModulePackageJson.java
Outdated
Show resolved
Hide resolved
...in/java/tech/jhipster/lite/module/infrastructure/secondary/FileSystemPackageJsonHandler.java
Outdated
Show resolved
Hide resolved
I still in draft because I am going to update the modules in this pull request too 🖖 |
I identified the sonar bug, and I will fix it later 👍 |
...ava/tech/jhipster/lite/module/infrastructure/secondary/FileSystemPackageJsonHandlerTest.java
Outdated
Show resolved
Hide resolved
src/main/java/tech/jhipster/lite/module/domain/packagejson/PackageJsonChanges.java
Outdated
Show resolved
Hide resolved
src/main/java/tech/jhipster/lite/module/domain/packagejson/JHipsterModulePackageJson.java
Outdated
Show resolved
Hide resolved
6f1ba5a
to
efde02c
Compare
I encounter a new issue when trying to replace this I see two possibilities:
I am going to try to implement the second option because this jestSonar block is only needed at AngularModuleFactory and is not generic enough to deserve an implementation at packageJson API. |
@murdos : I implemented |
@@ -0,0 +1,10 @@ | |||
package tech.jhipster.lite.module.domain.packagejson; | |||
|
|||
record PackageJsonData( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm really not found of this (and is the reason why I've not approved this PR earlier). It brings some unneeded coupling.
If Sonar is not happy about duplication for these pieces of code, we can disable the rule locally with a @SuppressWarning
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm really not found of this (and is the reason why I've not approved this PR earlier). It brings some unneeded coupling.
I can't agree more! It was only to make sonar let me go.
If Sonar is not happy about duplication for these pieces of code, we can disable the rule locally with a @SuppressWarning.
That's great news!!! I am going to revert this change and add the supresswarning!!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I remove the need for PackageJsonChanges.java
using the context from JHipsterModuleChanges
. This will also address the code duplication issue identified by Sonar as a secondary benefit.
BTW: I didn't find a way to ignore sonar code duplication using @SuppressWarning
. I am curious if I didn't search enough, I would like to know if you know how 😃
...in/java/tech/jhipster/lite/module/infrastructure/secondary/FileSystemPackageJsonHandler.java
Outdated
Show resolved
Hide resolved
13ab437
to
5bfbc94
Compare
912683e
to
092d563
Compare
…ers with context values
…lied Whereas JHipsterModulePackageJson represents the desired changes declared with module builder api. That way JHipsterModuleContext is only used for PackageJsonChanges, but not for JHipsterModulePackageJson
…sterModuleChanges and pass through parameter to who need it.
… at angular-core module
… at thymeleaf-template modules
… JHipsterModuleChanges. This will also address the code duplication issue identified by Sonar as a secondary benefit
Fix #9744