-
-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Add support to JDL entities at CI scripts. #13204
Conversation
- Implement 11-generate-config.sh script
#------------------------------------------------------------------------------- | ||
# Generate jdl entities | ||
#------------------------------------------------------------------------------- | ||
jhipster --no-insight jdl "$JHI_SAMPLES"/jdl-entities/*.jdl --json-only |
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.
Using JDL for generating entities is nice, but I'd prefer another approch:
- I'd remove this part for sqlfull
- use another variable: JHI_JDL_NAME
- use another if block:
if [[ "$JHI_ENTITY" == "jdl" && "$JHI_JDL_NAME" != "" ]]; then
jhipster --no-insight jdl "$JHI_SAMPLES"/jdl-entities/$JHI_JDL_NAME.jdl --json-only
elif
So it will improve our current CI, don't have any impact for daily builds, blueprints, etc.
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.
"$JHI_ENTITY" == "jdl"
is used for generating the entire project using jdl, it would make this PR useless.
b9494e2
to
5d7c3dc
Compare
@pascalgrimaud this PR is to simplify entity test cases like https://github.com/jhipster/generator-jhipster/blob/c058e12ba363b815f28ca5b635413f0a42266644/test-integration/samples/jdl-entities/custom-id.jdl. With current implementation I would have to create 8 different files instead of 1. |
So if I understand well, the final idea is to replace all entity json files to JDL, am I correct ? |
That's an option to consider. |
Yes, I'm fine.
Then, in main generator-jhipster, we can use JDL now. It would be easier for us to reproduce the failures |
@mshima : do you need this PR beeing merged to advance on other PR ? |
@pascalgrimaud I've create several PRs to reduce the size of PRs and simplify the review and merge process. |
JDL entities must be executed after copying
.yo-rc.json
and before generating the project (jhipster --with-entities
).11-generate-config.sh
and deprecate11-generate-entities.sh
11-generate-config.sh
copy.yo-rc.json
, json entities and generates entities from jdl afterwards.Please make sure the below checklist is followed for Pull Requests.
When you are still working on the PR, consider converting it to Draft (bellow reviewers) and adding
skip-ci
label, you can still see CI build result at your branch.