Skip to content

How to change base repo for gh pr? #2300

@mehagar

Description

@mehagar

Describe the bug

I originally used the gh pr create command, which prompted me to pick a base repo. I picked my forked repo instead of the upstream one, and now I'm unsure how to change the base repo so I don't need to prefix every command with --repo. Is there any way to do this?

Steps to reproduce the behavior

  1. Fork some repo
  2. Clone repo locally
  3. create local branch
  4. gh pr create
  5. Pick the forked repo as base.

Expected vs actual behavior

I expected there to be a command like gh repo set or something that will let me configure what the base repo for pushing should be.

Logs

Metadata

Metadata

Assignees

Labels

coreThis issue is not accepting PRs from outside contributorsenhancementa request to improve CLI

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions