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: | New Project and Shared Libraries breaks Mercurial Plugin or does it? | ||
---|---|---|---|
Product: | versioncontrol | Reporter: | John Rice <jrice> |
Component: | Mercurial | Assignee: | issues@versioncontrol <issues> |
Status: | RESOLVED FIXED | ||
Severity: | blocker | CC: | dkonecny, jglick, mkleint, mkubec, msandor, padraigob, pjiricka |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | Sun | ||
OS: | All | ||
Issue Type: | ENHANCEMENT | Exception Reporter: | |
Attachments: | main_work_70665_b1bc8c98e314-#127987-sources-outside-project2.patch |
Description
John Rice
2008-02-21 09:33:09 UTC
IMHO creating a new repository is a rare and serious activity which should not be exposed through the IDE's GUI to begin with. Certainly the IDE should never decide on a repo root on its own; if there must be an "Init" command in the GUI, the user should be prompted with a filechooser where the root should be. "creating a new repository is a rare and serious activity which should not be exposed through the IDE's GUI to begin with" Really? If you are setting up a large scale OpenSource project then for sure it's a rare activity, but if you are just hacking away on your own pet projects and want the benefits of VCS or are working with a few others then it could be quite a common experience and I think the GUI should make it simple and easy to do. The question remains here if I create a New Java Application and put it under local Hg control, I would expect things to just work. Now with the shared libraries being created at the same level as the JavaApplication we need to figure out what we should do. Do we put up a file Chooser dialog and ask them to choose, they might rightly wonder why when we bring it up we put them at a level above the JavaApplication they are creating. "creating a new repository is a rare and serious activity which should not be exposed through the IDE's GUI to begin with" Really? If you are setting up a large scale OpenSource project then for sure it's a rare activity, but if you are just hacking away on your own pet projects and want the benefits of VCS or are working with a few others then it could be quite a common experience and I think the GUI should make it simple and easy to do. The question remains here if I create a New Java Application and put it under local Hg control, I would expect things to just work. Now with the shared libraries being created at the same level as the JavaApplication we need to figure out what we should do. Do we put up a file Chooser dialog and ask them to choose, they might rightly wonder why when we bring it up we put them at a level above the JavaApplication they are creating. My suggestion: if the project has any generic source roots not inside the project dir, such as ../libraries, warn the user and bring up a filechooser. Otherwise assume they want to use the project dir (and maybe bring up a filechooser anyway, but that's just my opinion). My two cents: I would question using project folder as root of repository. One VCS repository per project? That does not sound like reasonable default. Unless it is HelloWorld application which you not gonna store in VCS anyway. I would say almost always your "product" will (or should) end up implemented as multiple NetBeans projects and you wanna have all these in one VCS repository. So we should not encourage users to create one project with huge monolithic source tree. Or am I missing something. OK - well with the libraries folder being created at the same level as the JavaApplicationX we need to address this issue. Proposal: Bring up a dialog which says something like: -------------------------------------------------------------------------------------------- This Project has source roots not inside the NetBeans project dir (refer to Output Window). (Mercurial repositories can only control code under the repository root) Common ancestor for sources. Repository root: [detected common ancestor dir] [Browse Button] If this is not what you want you may select your own repository root. [OK] [Cancel] [Help] mercurial should be able to deal with this situation somehow. I wasn'tin favour of making it the default (../libraries) but got convinced by other people that it indeed is the best default. Well NetBeansProjects is a scratch area for play projects. If people want to set up version control on some dir here, of course we should not prevent them, but neither should we worry too much about making it useful. Ok - so I will drop this down to a P3, as it is working as designed and make it an enhancement to bring up a dialog when doing a Initialize so a user can choose a different root if they wish. If the user is creating a project that will have sources outside the project dir we warn them that a common ancestor needs to be set for root and they can cancel if they do not wish this to happen. Created attachment 57527 [details]
main_work_70665_b1bc8c98e314-#127987-sources-outside-project2.patch
Patch pushed in da741f833d68. Don't forget to define a Target Milestone when closing any issue as FIXED. |