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

Smooth out the Set Upstream workflow #165

Open
dogweather opened this issue Jan 21, 2018 · 0 comments
Open

Smooth out the Set Upstream workflow #165

dogweather opened this issue Jan 21, 2018 · 0 comments

Comments

@dogweather
Copy link
Contributor

dogweather commented Jan 21, 2018

On git, after creating a local branch, and trying to push the commits upstream, one gets a very helpful error message which tells you what to do:

$ git push
fatal: The current branch tree-parser has no upstream branch.
To push the current branch and set the remote as upstream, use

    git push --set-upstream origin tree-parser

$ git push --set-upstream origin tree-parser    # Via simple copy & paste

That (1) tells you about the problem, (2) tells you how to fix it, (3) creates the new remote branch, and (4) sets it up as upstream.

In contrast, gitless only does (1):

$ gl publish
✘ No dst branch specified and the current branch has no upstream branch set
$ gl branch -su origin/tree-parser    # After consulting both online docs and CLI help message
✘ Branch "tree-parser" doesn't exist in remote "origin"

And there I give up and fall back to git. :-) IMO we should both tell people how to fix the problem, and also create the upstream branch automatically. People coming from git will expect this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants