Bug 122469 - Display correct repository folder according to project
Display correct repository folder according to project
Status: RESOLVED FIXED
Product: versioncontrol
Classification: Unclassified
Component: Subversion
6.x
All Windows XP
: P3 (vote)
: 7.2
Assigned To: issues@versioncontrol
issues@versioncontrol
: PLAN
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-11-21 09:59 UTC by tomzi
Modified: 2011-11-19 16:18 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tomzi 2007-11-21 09:59:12 UTC
1) Checkout Project A from svn (In my case maven projects)
2) Checkout Project B from svn
3) Click on Project A again and 'Switch To Copy'
-> in the popup (name: 'Switch Project A') it shows per default as an repository folder 'project-b/trunk' although
   in my opinion it should show 'project-a/trunk'. This would immensly reduce a lot of clicking if nb would 
   not just take the 'last used svn repository folder' but the one repository folder I just right clicked on. 
   With the current implementation I would have to search through all svn modules under 'Browse' again to find project-a. 
   This would mean in some cases going through a hundred or more projects. In the latter case 'project-b' would be 
   correctly opened and I just have to click a new branch
Comment 1 Tomas Stupka 2007-12-07 11:21:51 UTC
Not sure if i correctly understood the post. However - i'll try to make my point. 

1.) Maybe it would help in your case to preselect the repository folder with the path given by the selection. Or did you
mean only a part from it? I don't understand why do want to look for your branches under 'project-a/trunk'. However, the
problem i see is that your suggestion wouldn't work with some another repository layout.

2.) you have to do this once for the first time. The next time you only have to pick the branch folder from the combo.

3.) note that we have already an enhancement which should make the navigation in 'Browse' more comfortable. see issue
#110686

4.) WAD -> going to close for now. However, feel free to reopen this as an enhancement in case you should have a strng
opinion about this and we may try to find a generally working solution.

thanks

t. 

Comment 2 tomzi 2007-12-11 13:51:32 UTC
I'm not sure if you got what would be more helpful to have?

If you have 3 Projects in your Projects view:
+-Project A
+-Project B
+-Project C

All of them are checked into the SVN repository (eg. in the trunk). If for some reason you need to checkout
a branch of Project B. You need rightclick on Project B/Subversion/Switch to Copy...
Now a popup opens (called 'Switch Project B').

Now the problem is, that the 'Repository Folder' is usually prefilled with the last location you recently used this
dialogue for. So if I had switched Project-A to branch 'mybranch' before, it would say 'Project-A/mybranch' or something
like this. So when I click now 'Browse' it would give my all eg. 75 projects I have in the repository and I have to look
for my Project-B in order to switch to a different branch.

But I think it should NOT do this. Instead it should prefill the location of where the Project-A is currently at, so in
my case 'Project-B/trunk' and when I click 'Browse' it should already scroll down the list of 75 projects and preselect
and open 'Project-B'. So now its MUCH faster and easier to switch to my preferred branch.

Comment 3 Peter Pis 2007-12-12 09:37:51 UTC
IMHO, this can't be implemented in reasonable way to cater for the needs of all because Subversion allows various
repository layouts ("trunk, "branches" and "tags" are just standard directories)
Comment 4 Tomas Stupka 2007-12-12 12:46:46 UTC
1.) agree with ppis and also as i already mentioned in my previous post. I don't thing this would work for another
repository layout like e.g. 

trunk + projectA
      + projectB
      + projectC
branches 
tags

see also - http://svnbook.red-bean.com/en/1.4/svn-book.html#svn.branchmerge.maint.layout
for recommended repository layout and also note that projects and what we call 'branches' in a svn repository may be
setup in a way which quite differ from the one used by you. The suggested solution wouldn't work in general.

2.) and again, one more thing i already mentioned in my previous post - note that we have an enhancement which should
make the navigation in 'Browse' more comfortable. see issue #110686. Seems to me like a more general solution how to
pick a folder from a long list.


Comment 5 tomzi 2007-12-16 00:53:02 UTC
Hmm, I do understand that - but i guess in 95% of there will be only a view different variations:
1) I guess most of the svn will use some naming convention: trunk/branch/tags
2) There maybe only 3 major layouts:
(trunk|branch|tags)/projectXX or projectXX/(trunk|branch|tags) or just projectXX (or maybe 1 or 2 others)

All these layouts could be detected in a couple of tests, if no layout could be detected, you could always use a default
behaviour, which will in a wild quess only hit less the 5% of all the cases. All the other projects will have a great
useability gain.
Comment 6 tomzi 2007-12-19 08:38:34 UTC
I still do not think, this is an invalid request. Reopen the issue again, unless you object, then feel free to resolve
it again, since I can see that exactly my requested behaviour is implemented in eclispe and it works very well.
Comment 7 Ondrej Vrabec 2011-10-06 14:06:39 UTC
(trunk|branches|tags)/project layout is already supported, we could add also project/(trunk|branches|tags)
Comment 8 tomzi 2011-10-11 09:27:52 UTC
nice :)
Comment 9 tomzi 2011-10-11 09:31:26 UTC
does not seem to work with

Product Version: NetBeans IDE 7.1 Beta (Build 201109252201)
Java: 1.7.0; Java HotSpot(TM) 64-Bit Server VM 21.0-b17
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
User directory: C:\Users\thomas.zillinger\.netbeans\7.1beta
Cache directory: C:\Users\thomas.zillinger\.netbeans\7.1beta\var\cache

yet. I guess its still in a dev branch. 
"project/(trunk|branches|tags)" would also be helpul :)
Comment 10 Ondrej Vrabec 2011-10-11 09:47:54 UTC
> does not seem to work with
It should, see #198995. What is the folder's repository path you're trying to switch and what can you see in the combo in the switch dialog?
Comment 11 Ondrej Vrabec 2011-11-18 11:37:32 UTC
http://hg.netbeans.org/core-main/rev/9371b46db811 merged into trunk. Repository URL selector now supports also ABC/.../trunk|branches|tags/... schema
Comment 12 Quality Engineering 2011-11-19 16:18:13 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/9371b46db811
User: Ondrej Vrabec <ovrabec@netbeans.org>
Log: #122469 - Display correct repository folder according to project
smart repository url selector supports also repository schemas where tags|branches|trunk do not lie directly in the repository root folder


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo