kelemen / netbeans-gradle-project

This project is a NetBeans plugin able to open Gradle based Java projects. The implementation is based on Geertjan Wielenga's plugin.
172 stars 57 forks source link

Please update Profiles to document how to 'Activate a profile' #319

Open aplatypus opened 7 years ago

aplatypus commented 7 years ago

I am looking for the action to use a Gradle plugin profile other than "Default". There is no information on the Gradle profiles page, or any of the linked pages.

An example usecase. I have defined two profiles for run-time and debug-time command parameters. One uses a service on the localhost, the other uses our test server with an IP address.

Whenever I run with the debug or run option only the default profile is run. I know this because if I manually paste settings from one of the two profiles, then that server is used.

Whenever/however I try to select a different profile, it always runs with the default profile. I haven't found a menu or setting to change "Active profile", other than the profile drop-down on the project properties panel (so far).

Comparing behaviour with the Netbeans classic profile panel. When I selected a profile with the drop-down box, that was the profile that got used when we run the debugger, until we changed the profile setting On The Properies panel. The Gradle plug-in is working differntly to this and I suggest that is a flaw in the - Profiles documentaton.

I was trying to make sense of the instructions given for Issue #313, whcih seems needlessly cumbersome. And also it looked as if the developer needs to program his build to action profiles. I hope that's just something extra that guy wanted to do. I consider the purpose of profiles by-and-large is to AVOID needing to edit script of builds so you can repeat the same processing across different configurations/contexts, etc.

related:

aplatypus commented 7 years ago

... Since posting I found that the menu option works for Gradle profiles. I'm adding that here in case anyone else is wanting to do this. I still think the wiki page is the best place. And it wouldn't be a not-good thing to allow the selected profile from the drop-down to remain as the classic netbeans does it.

Process:

kelemen commented 7 years ago

It was many years since I have last used the Ant based project type (just tried it again) but I'm not sure what is exactly your expectation. Can you describe exactly what you did and did not result in the selection of your profile? You can surely select a profile with the combo box on the toolbar (as that combo does the exact same thing as the one in the Run menu (to be honest I didn't know that it is there as well).

By the way, if you want to improve the wiki, it is publicly editable (and also available as a git repository at https://github.com/kelemen/netbeans-gradle-project.wiki.git).

kelemen commented 7 years ago

Also, I have adjusted the profiles page. I hope it is more clear this way.