Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 340968 - [client][git] make clone git repo more friendly
Summary: [client][git] make clone git repo more friendly
Status: RESOLVED FIXED
Alias: None
Product: Orion
Classification: ECD
Component: Client (show other bugs)
Version: 0.2   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 0.2   Edit
Assignee: Malgorzata Janczarska CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 343325 (view as bug list)
Depends on:
Blocks: 345307
  Show dependency tree
 
Reported: 2011-03-25 10:59 EDT by Felipe Heidrich CLA
Modified: 2011-09-01 11:42 EDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Felipe Heidrich CLA 2011-03-25 10:59:52 EDT
running all client code from HEAD

click on clone git reposiroty button

the first field is 'Reposiroty URL', it was not clear to me which URL to use:

git://git.eclipse.org/gitroot/e4/org.eclipse.orion.server.git
ssh://git.eclipse.org/gitroot/e4/org.eclipse.orion.server.git
http://git.eclipse.org/gitroot/e4/org.eclipse.orion.server.git

Using the one that starts with http worked for me, using the URL that start with git cloned a bare repository (I think). Either way, it could be simpler.

I didn't know what to put on the ssh know host field, so I left it blank and it worked fine. If the field is option, the user should know.

After I clicked okay the dialog closed and there is no indication of what is happening (no progress bar, no message in status line, anything).
After a few second an alert window opened with a path for me to link to. I could not select and copy the path, after I closed the window I could not find that path again. I had to clone the repo again and this time I made sure to memorize the path before closing the window.
I should have being able to select the path and copy it to the clipboard.
Even better, the files should be visible on my workspace after the clone operation (orion could be nice and link the repo to my workspace for me).
Comment 1 Szymon Brandys CLA 2011-03-25 11:04:24 EDT
You are right. We will move the CloneRepo action to the Git repositories view and will try to make it more friendly.
Comment 2 Tomasz Zarna CLA 2011-04-04 05:03:44 EDT
(In reply to comment #0)
> After I clicked okay the dialog closed and there is no indication of what is
> happening (no progress bar, no message in status line, anything).

Bug 334140 and bug 341673 are about to change that.
Comment 3 Susan McCourt CLA 2011-04-19 20:26:42 EDT
*** Bug 343325 has been marked as a duplicate of this bug. ***
Comment 4 Susan McCourt CLA 2011-04-19 20:27:25 EDT
I find several things to be confusing about the git clone command:

- it only clones the repository, it doesn't actually link it into my workspace.
 Presumably I'm to figure out how to do this using the status message that
tells me where the cloned repo resides.  Ideally it should just link
automatically for me.

- why is the icon ever present at all levels of the nav?  To me it seems like a
peer to "link project."  It should just be visible when I'm at the nav root. 
Otherwise I'll have to navigate to the root in order to link to the cloned
repo.

Note that when we have a landing page (bug 343290) it can be even easier to
create a project from a cloned repo.  But until then, I think we should make
the git clone command appear only in the nav root and it should do the link for
you.
Comment 5 John Arthorne CLA 2011-04-20 09:09:01 EDT
(In reply to comment #4)
> - it only clones the repository, it doesn't actually link it into my workspace.
>  Presumably I'm to figure out how to do this using the status message that
> tells me where the cloned repo resides.  Ideally it should just link
> automatically for me.

The problem is linking the entire repository might not be what you want. Maybe you're only interested in working on one project/folder in the repository. In egit this is a two step process, where you create clones, and then you can import folders from those clones into your workspace. I like this model because it allows the user to assemble an uncluttered list of the folders they actually care about rather than having to tunnel down through the whole repository.

> - why is the icon ever present at all levels of the nav?  To me it seems like a
> peer to "link project."  It should just be visible when I'm at the nav root. 
> Otherwise I'll have to navigate to the root in order to link to the cloned
> repo.

I would even be tempted to remove the clone command from the nav entirely, and just add a link in the header next to Navigator / Sites /Plugins to get to the clone view page. Otherwise we are going down the route of pulling lots of git functionality and scripts into the navigate page.
Comment 6 Szymon Brandys CLA 2011-04-20 09:19:24 EDT
Git Clone command will be moved to Git Clone UI at some point. However our Git Clone UI is not in a shape where we could choose any node from the working tree and link it to the workspace. Thus we have Git Clone command in Navigator UI.
Comment 7 Boris Bokowski CLA 2011-04-20 09:23:53 EDT
(In reply to comment #5)
> The problem is linking the entire repository might not be what you want. Maybe
> you're only interested in working on one project/folder in the repository. In
> egit this is a two step process, where you create clones, and then you can
> import folders from those clones into your workspace.

If you are using the Git command line, you get the complete repository. IMO, this argues strongly for doing what Susan suggested. My guess would be that the two-step process in EGit is there because the Eclipse IDE treats projects in a special way, and you want to make sure that the "right thing" ends up at the project level.
Comment 8 Boris Bokowski CLA 2011-04-20 09:25:07 EDT
In general, I think it is more important to not surprise a typical Git user than it is to not surprise a typical Eclipse user.
Comment 9 Szymon Brandys CLA 2011-04-20 09:50:44 EDT
(In reply to comment #7)
> If you are using the Git command line, you get the complete repository. 

On second thought I think that Git Clone should work in a similar way to Import command. We should select a folder in the workspace and clone a repo there. It would be a real console experience. However it means that Git service should understand file locations (URIs), i.e.

Git Clone operations should get a folder location like /file/[folderPath]
Comment 10 Malgorzata Janczarska CLA 2011-04-20 10:21:44 EDT
This is my idea of how could we solve the problem with linking leaving it as two step process
1. move git clone command to view with git clones list (it's now called git clones, maybe we should call it git repositories?)
2. add a link to git clones next to "Navigator Sites Plugins"
3. refresh the clones list when clone action is finished (actually it's already implemented)
4. add a link command to each repository in the list

As for linking to subfolders of the repository I see one problem: we don't display repositories content anywhere. So if a user would like to link to a subfolder he would have to know exactly its path.
Comment 11 Susan McCourt CLA 2011-04-20 12:15:25 EDT
(In reply to comment #10)
> This is my idea of how could we solve the problem with linking leaving it as
> two step process
> 1. move git clone command to view with git clones list (it's now called git
> clones, maybe we should call it git repositories?)
> 2. add a link to git clones next to "Navigator Sites Plugins"
> 3. refresh the clones list when clone action is finished (actually it's already
> implemented)
> 4. add a link command to each repository in the list

I like this.

> 
> As for linking to subfolders of the repository I see one problem: we don't
> display repositories content anywhere. So if a user would like to link to a
> subfolder he would have to know exactly its path.

I had problems in the past where I couldn't see the git commands when I linked to repos that were below the main directory.  Is this still the case, or is that problem not possible since we are now using Orion to do the clone.  (In my case I had cloned using other git tooling so when I linked to a specific subdirectory Orion had no idea this was git.  I had to link to the root to see the git commands).  

I think we should just add the link command to each repo, and if the user wants to look at something at a different level, they can add it to "favorites."  That is how I work today, I have favorites to specific drill-down points where I do my work.
Comment 12 Szymon Brandys CLA 2011-04-21 03:56:05 EDT
(In reply to comment #11)
> (In reply to comment #10)
> > This is my idea of how could we solve the problem with linking leaving it as
> > two step process
> > 1. move git clone command to view with git clones list (it's now called git
> > clones, maybe we should call it git repositories?)
> > 2. add a link to git clones next to "Navigator Sites Plugins"
> > 3. refresh the clones list when clone action is finished (actually it's
> already
> > implemented)
> > 4. add a link command to each repository in the list
> 
> I like this.

We agreed for this approach some time ago. However I think that we should discuss the one described in comment 9. This approach would be consistent with our Import operation and is more handy IMO.

> I think we should just add the link command to each repo, and if the user wants
> to look at something at a different level, they can add it to "favorites."  That
> is how I work today, I have favorites to specific drill-down points where I do
> my work.

It looks like we would end up somewhere between EGit and console approach. Git Repositories UI would be this EGit part and linking a repo to the workspace root would take us to the console world. 

As I'm suggesting above we should make a step further and just clone repos pointing at a folder in the workspace (like during the Import operation). Then Git Repositories UI would be just a view on available repositories in the selected workspace.
Comment 13 John Arthorne CLA 2011-04-29 10:21:51 EDT
Some improvements have been made here but we can refine further in M8.
Comment 14 Malgorzata Janczarska CLA 2011-06-01 10:43:15 EDT
I think we made GIT cloning much more friendly now:
1. known hosts are added automatically by confirmation
2. credentials dialog is opened only when authentication is required
3. No need for linking it to a directory any more

I'm marking this bug fixed, if anyone has some more usability issues please open individual bugs for them.