Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Development Tools

James Nelson
James Nelson
23,956 Points


Hello guys, I am trying to teach myself how to use Github after watching the Git videos on treehouse.

I have set up a repo on Github and have set up an additional dummy account that I am using to fork the repo, make a change and thus create a pull request on my original account.

The steps I am taking are as follows:

  1. Fork original repo on dummy account
  2. Clone repo using https and cd into the create folder
  3. Use nano to add a file and save it
  4. Add and commit these changes
  5. git push -u origin master

On doing I get the following error and have not been able to resolve this:

fatal: unable to access 'https://github.com/jamesnelson2/Badassgraph.git/': The requested URL returned error: 403

Any ideas?

2 Answers

Since you are using two Github accounts, your Git credentials need to change locally on your machine depending on what repo you are pushing to.

Also, depending on what your origin master is locally on your machine, depends entirely if you have permission to push to a repo.

Is your dummy account registered as a collaborator to make changes to your main account repo?

Example how Github is suppose to work if a person doesn't have permission to make changes to a repo:

User A makes a repo

User B sees the repo

User B forks user A's repo on their Github account

User B clones, to their local machine, from their personal copy url available on their Github account

If user B wants to contribute to user A's repo, they need to push changes from their local machine to their personal copy of A's repo on their Github account.

User B goes on Github and finds their personal repo they just pushed to.

User B creates a "New pull request"

User A decides if they want to accept the pull request or not.

James Nelson
James Nelson
23,956 Points

Hello and thanks for you're reply,

Yes my dummy account has been set as a collaborator and what you described is exactly what I am trying to do. Note that I am using the one machine, would that be the cause of my issue?