-
Notifications
You must be signed in to change notification settings - Fork 102
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
Extend/improve Gradle project wizard #306
Extend/improve Gradle project wizard #306
Conversation
Drop down options are represented by Enums. Adding a new option is as simple as:
|
Looks interesting! Does this solve any of the issues with the current template, as well? Would you consider looking through the analysis issues? It seems a lot of them could be solved by simply running the auto-formatter. |
Very awesome :) Without having looked at the code, yet:
Speaking of the example build.gradle file: We need to remove jcenter() as that is taken offline. I'll have a look at the code and test the feature soon! thanks! |
The code is looking good 😄 . Did you have prior experience with Netbeans or did you just learn that by doing? |
@MeFisto94 thank you for your kind words and feedback:
The most recent thing I saw was this jFrog update saying jCenter was going to be kept read-only indefinitely now? Is it ok to leave it in? I wanted to be able to offer @pspeed42 's Zay-ES etc as recommended 3rd party libraries and jCenter seems better to use than JitPack if possible...
Will find some time to fix this week/weekend 👍 Do you prefer me to push an additional commit (so you can easily see the changes), or to squash + force push so it is ready to merge?
I've submitted a handful (of admittedly fairly straightforward) PRs to the main NB project 👍 @neph1 Thanks for taking a look!!:
The assets project should work nicely, which was my initial inspiration (although @MeFisto94 fixed that in the existing template whilst I was working on this). The project and asset projects will display properly in the SDK now, as NB picks them up from the A part 2 to this PR should be to create build targets for Desktop / Android / iOS, and initialise the Gradle project using NB's gradle wrapper class (to do a
I think most of them are caused by using the NB Matisse GUI builder, and the static analysis hates the code it produces. But as @MeFisto94 says, there are probably also some legit problems in there. I'll sift through this week/weekend and tidy up where needed 👍 |
Then that's okay, still not really awesome, but if paul hasn't migrated yet, that probably means we should keep it for ease of access, as you say.
Just do an additional commit. I mean in this case only the final form matters and not the intermediary changes, but github can easily squash merge for us anyway.
I think this should be an engine discussion, or rather: already is. I think I created an issue once and there may even be pending PRs with other suggestions |
@MeFisto94 I've added some additional commits:
Hopefully, that is enough for now? As I said, if there is a community consensus on what an ideal multi-target project structure should look like, I'll happily come back and redo parts of this :) |
I also realised I made a mistake with the .zip file, so that is fixed now too |
Paul has migrated :) |
Nice work! Assets do work, that is confirmed. I think all around solid work :) I hope it is not too daunting for the first time user, so many mystical selections. The template gives only one warning: That is the topic you also discussed. But I think this is definitely a good start! I'll leave this to @MeFisto94 |
While jCenter may now be replaced by paul, we'll probably defer that to the new multi-target project structure at some point, so it's good to go. This is because older versions still are on jCenter then, I guess. Actually: Does the template seamlessly allow you to use pauls more recent libraries? I guess since the artifactId stays the same, it should "just" work? |
@MeFisto94 - yes, just need to change the version number in the Saying that, I've updated the enums with the latest version of JME (3.5.2-stable), all of Paul's libraries and Stephen's libraries.. |
@peedeeboy sorry about the hassle. Could you resolve the conflicts and lets then merge this? |
691299c
to
f39654c
Compare
@tonihele - squashed, rebased and tested on 3.4.1 SDK 👍 |
Nice work, I'll run it through first thing tomorrow! |
Summary
Based on the jmeinitializer, this PR aims to add similar functionality to the JME SDK itself. In the future, the SDK could be update to call the initilizer API to get a new Gradle project (this is how the NB Spring Boot plugin works..).
The new Gradle game wizard now uses NB's built in FreeMarker template engine to replace the
build.gradle
andsettings.gradle
files from the .zip with templated versions depending on what the user selects.Templating the
settings.gradle
means the Project will display with the correct name in NB's Project Window.New wizard workflow
Example
build.gradle
TODO
This could be further expanded to user NB's built-in Gradle wrapper class to run
gradle init
, this would allow the user to set the Group etc. and would allow create of sub-projects for different build targets (iOS, Android etc.). I don't know enough about jMonkey build targets outside of Linux/Windows desktop yet though, so decided to submit this PR as-is for now...