Failing to update page #22232
-
I followed the instructions on github pages, the last command didn’t work so I used “git checkout -b master” Then it worked, but now when I try to push updated versions of index.html, no changes occur. |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments
-
You need to make sure to push to the branch that’s currently published, or if you really want to use a different branch go to the repository setting and select that branch for Pages. |
Beta Was this translation helpful? Give feedback.
-
I tried git push -u origin main, and got
I tried updating the page with: now when i use git push index.html I get: Please make sure you have the correct access rights |
Beta Was this translation helpful? Give feedback.
-
levilone:
You can’t push a file. You need to commit the file to the branch that’s being published, and then push the branch. Here’s the Github documentation on pushing: Pushing commits to a remote repository - GitHub DocsFor a general introduction to git I highly recommend the Git Book, especially chapter 2. |
Beta Was this translation helpful? Give feedback.
-
thanks for the help, I was able to get it working after some messing around |
Beta Was this translation helpful? Give feedback.
You can’t push a file. You need to commit the file to the branch that’s being published, and then push the branch.
Here’s the Github documentation on pushing:
docs.github.com
Pushing commits to a remote repository - GitHub Docs
For a general introduction to git I highly recommend the Git Book, especially chapter 2.