This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Cannt create new groovy package in maven project | ||
---|---|---|---|
Product: | groovy | Reporter: | Skvorec |
Component: | Editor | Assignee: | Martin Janicek <mjanicek> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | tzezula, wadechandler |
Priority: | P2 | ||
Version: | 7.3 | ||
Hardware: | PC | ||
OS: | Windows 7 | ||
Issue Type: | DEFECT | Exception Reporter: | |
Attachments: | Patch fixing the issue |
Description
Skvorec
2012-05-25 15:37:40 UTC
Thanks for reporting this! Definitely valid issue --> Setting TM = Next Bumping this to a P2. The affect this has is that one must create separate directories, and from a usability perspective it is very difficult; I'm working on moving some Java stuff over to groovy, and just want my folder structure laid out versus trying to copy the whole thing and then removing stuff. The only other quick workaround is to go to the CLI and use mkdir with options to create parents. There is no way using the wizard. You can select "Resources" in the wizard for instance, and you can create a new package there, but there is not option in the new package wizard for Groovy, so you sit there looking at the screen going...ummm...oh...well I guess I can create some directories on the CLI or one directory at a time, but I know I can do that because I have used it before. Some new user would most likely tuck tail and run as it is very confusing. This may be an issue of the mvn support perhaps...seems it would be handy to be able to create a new package under some directory created under main/* or test/*, and that would allow the IDE to more likely be used to support other up and coming technologies which could be used through mvn. One workaround I just tested, for anyone who may find this, and which you can use in the mean time, is to use the new Folder wizard. In there you can type multiple directory names, and it will create them all for you. So, lets say you right click on the Groovy packages node. You can choose new Folder, and you could enter in org/mydomain/myproduct/mypackage, and then press enter, and it will create them all for you in one shot. Still, although a viable workaround in this case, it is still confusing if you don't know about it, and to find out about it, you must look in the right place and know how to find it...at this point...this issue. Agree with you Wade, this is pretty annoying. The issue is here because our Groovy code currently use "Java package" wizard as it is. And the author of the code probably didn't expected that someone might need to create java package in a different folder than the standard one. I'll fix it for NetBeans 8.0 Created attachment 137998 [details]
Patch fixing the issue
Patch fixing the problem. Changes are in java.project module, class NewJavaFileWizardIterator where we need to check also for groovy source groups.
Tomasi could you please take a look at the patch ? I made small changes in java.project - NewJavaFileWizardIterator to be able to fix this issue. Thanks Seems OK to me. Thanks! Pushed in: web-main #4f9d87ec5f25 Integrated into 'main-silver', will be available in build *201307302300* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/4f9d87ec5f25 User: Martin Janicek <mjanicek@netbeans.org> Log: #213024 - Cannt create new groovy package in maven project |