New Grails 6 CLI/FORGE: What it changed and what was deprecated/removed #13562
Replies: 3 comments
-
Thank you for collecting this useful information. Here's a related discussion about the motivation behind the development of the new CLI/Forge.
|
Beta Was this translation helpful? Give feedback.
-
More discussion on #13569 |
Beta Was this translation helpful? Give feedback.
-
I think the term deprecate got lost in translation and ended up turning into the word drop |
Beta Was this translation helpful? Give feedback.
-
With the New Grails 6 CLI/FORGE, material changes were made to new default applications in Grails, especially 6.2.x, and those changes do not seem to be well known or understood yet. These changes unfortunately invalidate many historical stack overflow questions, blogs posts and other historical documentation in addition to portions of the currently published latest Grails documentation.
For a new default grails application, should the Grails Shell, Custom Scripts and Grails Profiles have been removed this quickly or should they have coexisted a bit longer with the new CLI/FORGE, until clearer paths were documented for all prior functionality, especially the new to grails basics?
It is still possible to use/add Grails Shell to a Grails 6 app and continue to use Custom Scripts,
grails create-* [DOMAIN_CLASS_NAME]
,grails generate-* [DOMAIN_CLASS_NAME]
,grails test package
andgrails dbm-gorm-diff <<filename>>.groovy --add
commands by adding the grails-shell dependency. Versus the new gradle with GrailsApplicationCommand waygradlew runCommand "-Pargs=generate-controller [DOMAIN_CLASS_NAME]|*
implementation "org.grails:grails-shell:6.1.2"
The following was still needed in dependencies for my 6.2.0 app to run. That doesn't align with profiles being removed.
profile ("org.grails.profiles:web")
#13399
https://grails.org/blog/2023-08-03-introducing-new-grails-forge.html
https://medium.com/@puneetbehl/a-comprehensive-guide-to-custom-application-command-in-grails-framework-f7496406ac50
"Since Grails 6, we stopped using/creating Grails profiles." "The New Grails Forge also introduces Grails Profiles through application-types"
"While the revamped CLI offers enhanced performance, it operates entirely offline, lacking awareness of the Grails application or its plugins. This change disrupts the traditional approach to executing custom scripts within the Grails environment. Previously, developers could create custom scripts to automate tasks or extend functionality. However, with the CLI’s new offline mode, the concept of custom scripts becomes obsolete."
"With Grails 6, we're embracing a new era where the Grails CLI wrapper will no longer be included in new projects."
#13116
https://github.com/grails/grails-core/issues/13103 - environments are still supported, but the generated application.yml didn't include them as it has historically
#13512
#13499
#13108
Beta Was this translation helpful? Give feedback.
All reactions