Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upInclude owner in default path when cloning a repository #1906
Conversation
jcansdale
added some commits
Sep 10, 2018
This comment has been minimized.
This comment has been minimized.
|
Question: Feedback:
Both of which are fine as they are since a user will likely select a new local clone path they're happy with if something undesired happened. I think this works really nicely and will be helpful at providing more structure for those who have lots of repositories from different owners or organizations. |
This comment has been minimized.
This comment has been minimized.
|
Thanks for taking a
Yup, I always organize my folders in a way that mirrors GitHub. I'll often clone a few repositories from the same owner. It's the only way I can keep any kind of order!
It would be easy enough to reset back to the default clone location if the user removes the full path. I think if someone was to do this, that is what they'd be hoping for?
I'll see if this can be fixed as well without any undesirable consequences. I think its okay for the reason you mentioned, but maybe it could be better. |
jcansdale
added some commits
Sep 11, 2018
This comment has been minimized.
This comment has been minimized.
|
I've fixed the two scenarios that you mentioned and added them to the list. I've also fixed an an edge case where the owner and repository had the same name. Previously it would only delete the repository rather than both. |
jcansdale
changed the base branch from
refactor/clone
to
master
Sep 11, 2018
jcansdale
requested review from
grokys and
meaghanlewis
Sep 11, 2018
This comment has been minimized.
This comment has been minimized.
|
This LGTM! |
grokys
approved these changes
Sep 13, 2018
|
Just one tiny thing, but other than that looks good! |
| @@ -114,12 +114,10 @@ public async Task Path_Is_Initialized() | ||
| public async Task Repository_Name_Is_Appended_To_Base_Path() |

Formed in 2009, the Archive Team (not to be confused with the archive.org Archive-It Team) is a rogue archivist collective dedicated to saving copies of rapidly dying or deleted websites for the sake of history and digital heritage. The group is 100% composed of volunteers and interested parties, and has expanded into a large amount of related projects for saving online and digital history.

jcansdale commentedSep 10, 2018
•
edited
What this PR does
Rather than suggesting a flat folder structure when cloning a repository, suggest a folder structure that includes the repositories owner
DefaultClonePath/Owner/RepoNameDefaultClonePathportion of path (keep when new repo is selected)How to test
Immediately change default clone path
DefaultClonePathbefore selecting a repositoryowner\repohas been added to pathChange directory name after selecting repository
owner\repoin path has changedRemove repository name from path
repohas been added to pathRemove owner and repository name from path
owner\repohas been added to pathClear the path
owner\repoadded to pathRemove owner from path