Github Help [solved]
Github Help [solved]
I just starting out coding. I've gotten through tutorial 14 making the snek game. I am trying to get started with github, but when i clone from planet chili github. I cant get visual studios 17 to publish new branch to mygithub.. I only have option to push and when i try that it says "Branch 'SnekGame' does not exist in the repository. Can anyone help please?
Last edited by jamesmfox on September 3rd, 2017, 12:29 am, edited 2 times in total.
Re: Github Help
Figured it out:
after creating a branch in Visual Studios and adding a remote in repository settings
I had to open up cmd and "cd" into the repository folder
then typed in
after creating a branch in Visual Studios and adding a remote in repository settings
I had to open up cmd and "cd" into the repository folder
Code: Select all
cd C:\Users\username\source\repos\repositoryfolder
Code: Select all
git checkout branchname
git push -u githuburl
Re: Github Help
Good job mate! It seems that Visual Studio has changed how the push command works in 2017, and you can no long push a single branch to a specific repo without publishing it there first, but there also seems to be no way (from inside VS) to publish a branch to a specific repo when you are tracking multiple (and not just origin).
ON the bright side, good intro to git command line
ON the bright side, good intro to git command line
Chili
Re: Github Help
Thanks! Still wouldn't push even after git command line..
Kept saying remote doesn't have a branch by that name..
I just created a new repo on github and imported from planetchili..
then branched of from there.. Seems to be working with visual studios now..
https://github.com/JamesMFox/SnekGame/tree/Obstacles
Kept saying remote doesn't have a branch by that name..
I just created a new repo on github and imported from planetchili..
then branched of from there.. Seems to be working with visual studios now..
https://github.com/JamesMFox/SnekGame/tree/Obstacles
Re: Github Help
yeah, in truth the situation of having 2 remotes isn't that common. either you fork on github and then pull from your fork, or you pull from an account, change origin to your own repo, and then push.
Chili
-
- Posts: 4373
- Joined: February 28th, 2013, 3:23 am
- Location: Oklahoma, United States
Re: Github Help
The easiest by far in my opinion is to fork someones repo into your account and then click Open In Visual Studio from GitHub
If you think paging some data from disk into RAM is slow, try paging it into a simian cerebrum over a pair of optical nerves. - gameprogrammingpatterns.com