X Tutup
The Wayback Machine - https://web.archive.org/web/20200911235134/https://github.com/cli/cli/issues/1543
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No option to not "rename origin remote to upstream the fork" #1543

Open
musm opened this issue Aug 17, 2020 · 3 comments
Open

No option to not "rename origin remote to upstream the fork" #1543

musm opened this issue Aug 17, 2020 · 3 comments
Labels
bug

Comments

@musm
Copy link

@musm musm commented Aug 17, 2020

Describe the bug

A clear and concise description of what the bug is. Include version by typing gh --version.

Steps to reproduce the behavior

gh repo fork
? Would you like to add a remote for the fork? Yes
✓ Renamed origin remote to upstreamr the fork? (Y/n) y     !! (y is automatically entered, which what I don't want!)

I want gh repo fork not to rename origin remote to upstream.

Also not the spelling mistake upstreamr

gh version 0.11.1 (2020-07-28)

@musm musm added the bug label Aug 17, 2020
@mislav
Copy link
Member

@mislav mislav commented Aug 17, 2020

Hi, thank you for the feature request.

If the repository you are currently in already has an "origin" remote, what do you expect to happen when you run gh repo fork and choose that you want to add the remote for the new fork?

See also #847, which this ticket is most likely a duplicate of in my view. Do you agree?

@mislav mislav added enhancement and removed bug labels Aug 17, 2020
@musm
Copy link
Author

@musm musm commented Aug 17, 2020

Yes, sorry this is a duplicate.

I want the option not to rename origin.

There seems to be a bug because the following is shown

✓ Renamed origin remote to upstreamr the fork? (Y/n) y 

But as you can see y is automatically added without the option to say n. Also not the misspelling of upstream

@mislav
Copy link
Member

@mislav mislav commented Aug 17, 2020

There seems to be a bug because the following is shown

✓ Renamed origin remote to upstreamr the fork? (Y/n) y 

But as you can see y is automatically added without the option to say n. Also not the misspelling of upstream

I see! That's a bug. We only print Renamed origin remote to upstream https://github.com/cli/cli/blob/v0.11.1/pkg/cmd/repo/fork/fork.go#L228

But we print that on stderr, then another prompt follows on stdout asking Would you like to clone the fork?, and it seems like this is not displayed in the terminal in a sequential order as we had hoped, most likely due to buffering. I think the fix would be to display all messages on a single stream (stdout). /cc @vilmibm

@mislav mislav added bug and removed enhancement labels Aug 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.
X Tutup