Still Can't Push Repository to GitHub from Command Line (Mac)

I recently bought a new Mac, and even after setting everything up, I can’t push a repository to Github using the command line. I’ve taken each and every step, I’ve watch as many tutorials as I could, I’ve done everything I can possibly think of, and all I get is this:

Every. Single. Time.

I’ve tried resetting my password, I’ve tried using the access token, tried using different commands, I’ve even tried wiping my computer clean, and NOTHING has worked. Someone, please tell me what the hell I’m doing wrong. Or even better, tell me if there’s a reliable alternative to the command line. I’m so close to giving up on coding altogether.

I am incredibly stupid, so if you can please tell me the EXACT steps as if you’re trying to explain this to an alien, that would be great. And thanks in advance.

I don’t see a railsbookblog repository existing on your github account. There’s nowhere to push to if it doesn’t exist over there at github.com

Am I missing something?

Yeah sorry about that. I deleted it, thinking that would help. It hasn’t. I created the new repository here:

https://github.com/RedMargarita/BookBlogRails

I tried the same steps, once again getting the same authentication error.

You might need to reset the origin to the new url:

git remote -v

# look for a line that says origin, if it's there then:

git remote set-url origin https://github.com/RedMargarita/BookBlogRails.git

# if there is no origin then try:

git remote add origin https://github.com/RedMargarita/BookBlogRails.git

and then try to push again.

Hey don’t beat yourself too hard about it.

It took me a while to get used to git too.

I’m still half ass guessing what kind of command I need to key in everytime I use it now.

It has a bit of learning curve.

Try this app, https://www.sourcetreeapp.com/

This is what I use, and find it very easy to visualize what’s going on.

1 Like