Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.
This repository was archived by the owner on Jun 21, 2023. It is now read-only.

Be more flexible about the repository folder layout when opening from GitHub #2428

Open
@jcansdale

Description

@jcansdale

Is your feature request related to a problem? Please describe.

The current Open from GitHub dialog is quite opinionated about the repository folder layout and encourages users to arrange their repositories by owner and repositoryName.

image

It is important to know when a repository has already been cloned in order do display the, You have already cloned... banner and give the user an option to Open rather than Clone.

After doing a small survey, it looks like only ~ 42% (29 + 13 below) of users include the owner in their repository path. Small survey, sampling bias caveats apply. 😉

image

https://twitter.com/jcansdale/status/1183882040879529984

Because so it's important to detect when a repository has already been cloned, we should really accommodate the users who layout their repositories in a flat hierarchy!

Describe the solution you'd like

When a user clones a repository using GitHub Desktop, the default repository directory is inferred from the directory they're cloning into. We could extend to and infer both the default directory and the user's preferred repository layout.

This would enable flexibility of repository layout and allow users to set their default repository directory. The current setting can be found in Team Explorer under Git Settings > Default Repository Location (which isn't very discoverable).

Describe alternatives you've considered

  • Add an explicit default repository layout option. Users could choose something like $(Host)\$(Owner)\$(Repository) and have their preferred layout suggested when navigating and cloning repositories. This was quickly dismissed as being overly complicated. Currently even discovering the Default Repository Location setting can be a challenge. This problem is exacerbated by having separate settings for each version / SKU of Visual Studio,

  • Automatically look for repositories under both owner/repositoryName and repositoryName. This would be good for detecting repositories that have already been cloned, but we'd still have the problem of deciding which directory to suggest when cloning a new repository.

Additional context

Here is the mirror image of this issue in GitHub Desktop:

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions