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

Initial push fails if git config push.default current is not set #16

Open
pichfl opened this issue Sep 12, 2018 · 1 comment
Open

Initial push fails if git config push.default current is not set #16

pichfl opened this issue Sep 12, 2018 · 1 comment
Labels

Comments

@pichfl
Copy link
Contributor

pichfl commented Sep 12, 2018

⠹ Creating developError creating branch { Error: Command failed: git push --set-upstream
fatal: The current branch s.tenpas/730-brands-overview-page-is-rendered-twice has no upstream branch.
To push the current branch and set the remote as upstream, use

   git push --set-upstream origin s.tenpas/730-brands-overview-page-is-rendered-twice



   at makeError (/Users/sven/.config/yarn/global/node_modules/work/node_modules/execa/index.js:174:9)
   at Promise.all.then.arr (/Users/sven/.config/yarn/global/node_modules/work/node_modules/execa/index.js:278:16)
   at process._tickCallback (internal/process/next_tick.js:68:7)
 code: 128,
 stdout: ‘’,
 stderr:
  ‘fatal: The current branch s.tenpas/730-brands-overview-page-is-rendered-twice has no upstream branch.\nTo push the current branch and set the remote as upstream, use\n\n    git push --set-upstream origin s.tenpas/730-brands-overview-page-is-rendered-twice\n\n’,
 failed: true,
 signal: null,
 cmd: ‘git push --set-upstream’,
 timedOut: false,
 killed: false }
⠸ Synching to GitHub

via @zehnnach

To resolve this that setting should be checked and if not set, the upstream should be set manually.

@pichfl pichfl added the Bug label Sep 12, 2018
@p-fischer
Copy link

I think the cleaner solution is not to rely on the push.default setting, but to change the command as suggested in the error message, i.e. replace

git push --set-upstream

with

git push --set-upstream origin s.tenpas/730-brands-overview-page-is-rendered-twice

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

No branches or pull requests

2 participants