github-for-mac-issues
github-for-mac-issues copied to clipboard
No Push to GitHub button for repos with existing (non origin) remotes
I have some repos that I have never pushed to Github, but have pushed to Heroku. In those cases, I have a "heroku" remote, but no "origin". Adding these repos to this app automatically fills in the primary remote repository (in settings) with the "heroku" remote. For a lot of use cases, that might be desirable. However, once this is filled in, there seems to be no straight-forward method to push the code to a new repo on Github. The app only displays the "Push to Github" button if there are no remotes at all. (Note: I also tried to add the repo via the New Repo method and got an error noted in this issue... https://github.com/baldwindavid/github-for-mac-issues/issues/8)
Steps performed
- Go to Preferences > Repositories > Scan for Repositories - select existing outlined above
- view repo Settings - primary remote is set as "heroku"
- no "Push to Github" button displayed...only Sync Branch
How to fix
- open .git/config
- remove all remotes
- restart Github for Mac
- open repository in app
- "Push to Github" button now displayed
- press "Push to Github" and configure
- reopen .git/config and add the "heroku" remote back in