Skip to content

Automatically add upstream remote when cloning a fork via repo clone #620

@billygriffin

Description

@billygriffin

Describe the feature or problem you’d like to solve

When I clone a fork with gh repo clone command, my only remote is the fork repo. It makes a lot of sense to also have a remote for the parent repo. As discussed in #582 (comment), we want to use the GitHub suggested remote naming conventions.

Proposed solution

After cloning a fork, automatically add a remote for the parent repo and name it upstream.

We should also automatically add the remote when someone uses gh repo fork and says they would like to clone the repo locally.

Metadata

Metadata

Assignees

Labels

enhancementa request to improve CLI

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions