JasmineCT / portfolio

The starter portfolio repository, basically empty, but with a few helper files.
https://hopeful-morse-7f7dbf.netlify.com/
0 stars 0 forks source link

Can't push to origin #20

Open JasmineCT opened 3 years ago

JasmineCT commented 3 years ago

So I wanted to start fixing my website but all of a sudden I'm not able to push my commits. Keeps giving me this error.

Screen Shot 2020-10-27 at 11 25 58 AM

I googled and I came across a solution where I got to my repo on GitHub desktop, and to the branches panel. I notice there is a branch called "upstream/master". This solution said to merge it to the master branch, which I did and it was successful to merge. But i'm still not able to commit anything. Not sure what else to do, I've looked over other solutions but its gibberish to me. Any ideas what it could be? @thomasjbradley

thomasjbradley commented 3 years ago

Have you added any large files into the website? Videos?

JasmineCT commented 3 years ago

Not any new ones, the only one that I can really think of is the video banner on my home page that could be causing an issue. I see a commit on my history with the "update video/banner.mp4" but I never updated it, it's almost like it did it itself and it never went through to the master.

thomasjbradley commented 3 years ago

That banner is small enough in size that it shouldn’t bother the repo.

Does it think for a long time before this error message pops up?

JasmineCT commented 3 years ago

Hmm weird. Yah it loads for a while then the error message comes up.

thomasjbradley commented 3 years ago

Are there any really large files within your portfolio? Really big JPGs, AfterEffects files, PNGs?

JasmineCT commented 3 years ago

No i don't think so I haven't really added anything new to my portfolio. Everything has been the same since I first posed it (other then the domain)

thomasjbradley commented 3 years ago

Okay. We’re going to try something a little crazy. Open up Terminal on your computer, from within GitHub Desktop to make it go to the correct folder.

Type this:

git push --force origin master

It will prompt you for your GitHub username, type that in. Then it will prompt for your GitHub password, type that in—when you’re typing you’ll see nothing, hit Return when done.

JasmineCT commented 3 years ago

Okay I did that and terminal gave me this

Screen Shot 2020-10-29 at 11 15 55 AM
thomasjbradley commented 3 years ago

Type: git config credential.helper & send me a screenshot.

JasmineCT commented 3 years ago
Screen Shot 2020-10-29 at 11 21 12 AM
thomasjbradley commented 3 years ago

Type this and send me a screenshot: cat ~/.gitconfig

JasmineCT commented 3 years ago
Screen Shot 2020-10-29 at 6 59 46 PM
thomasjbradley commented 3 years ago

Okay—I think we need to change that file.

I want you to delete these two lines from that .gitconfig file:

[include]
  path = /Users/jasmine…

To get it opened, type this into Terminal. Make the changes when it opens in TextEdit, then save & close the file.

open -e ~/.gitconfig

Afterwards I wanna do the force push again:

git push --force origin master
JasmineCT commented 3 years ago
Screen Shot 2020-10-29 at 7 16 23 PM

Okay did that this is what is gave me

thomasjbradley commented 3 years ago

Do these commands in Terminal one at a time:

Then try the force push again.

JasmineCT commented 3 years ago

AHHH IT WORKED!!! YAY

Screen Shot 2020-10-29 at 7 22 21 PM

Do I need to do anything so it doesn't happen again?

thomasjbradley commented 3 years ago

Nope! Should be good to go forever!

JasmineCT commented 3 years ago

OMG Thank you so much Thomas! Literal life saver! Eternally grateful!!