Incomprehensible bug in my GitHub-Page - github

First, I apologize for posting this here because I imagine it's not in the right place ...: /
Here, I have a git repository on which I have a personal project, I had a little abandoned and then I plunge on it. Until now I had never had a problem but since today I have the following error:
Refused to load the image 'https://monrepo.github.io/favicon.ico' because it violates the following Content Security Policy directive: "img-src data:".
Failed to load resource: the server responded with a status of 404 (Not Found)
The problem comes (normally?) not from my code because locally I have no worries so I imagine there is a trick that blocks on the github side but what ?!
Thanks for your help! =)

Alright, it was just an inattention mistake. Before it was necessary to have a dedicated branch gh-pages but now the master branch (or any other branch) can be chosen to be the gh-page. Simply have to select it in the repository settings...

If the username differs from the repository name User/MyRepository then you have to go to the repository settings and mark GitHub Pages explicitly to publish it.
If your name matches the user then you dont need to explicitly publish it, but its done automatically considering "*.github.io".
So the format for automatic publishing is:
User/User.github.io

Related

How do I fix 404 error on Github Pages for a personal page I'm creating

I tried to access my GitHub page:https://adityakm24.github.io/ But it shows 404 pages not found. I looked for many tutorials online but couldn't come up with a proper solution. Adding /Index.html doesn't work either. But I am sure about adding the index.html in my repo and index.html file is in the master branch.
https://adityakm24.github.io/ means a User page, for a GitHub repository named <user>.github.io at, in your case, https//github.com/adityakm24/adityakm24.github.io
Make sure you have selected a Source in the settings of that repository: it should be master by default.
And your file must be index.html, not Index.html (it is case sensitive)
You need to choose the branch properly in the settings page as shown below
Go to settings>manage access>manage
Here I can point out two reasons why it is not coming up
Provide the proper 'homepage url' in your package.json. This is a very important step. Follow this convention- "https://{username}.github.io/{RepoName}/". Anything other than this will give 404 error.
Go to your github repository and select the gh-pages branch.(No other branch will work)

Very simple HTML resulting in 404 Not Found on GitHub Pages [duplicate]

Here is my GitHub repository on the gh-pages branch.
Everything looks good, I have my index.html, my CSS, JS and pictures folders.
But when I access http://roine.github.com/p1 I get HTTP 404 not found.
Any explanation and solution?
I had just one commit with all my files. I pushed an empty commit, refreshed the page and it worked.
git commit --allow-empty -m "Trigger rebuild"
git push
If this doesn't work, as #Hendrikto pointed out in the comments, check out the Github status page and make sure GitHub Pages are operational.
I did all the tricks on my repo to fix page 404 on Github Page (https://eq19.github.io/) but it kept 404'ing.
Finaly found that my browser hardly keep the 10 minutes cache before it up on the web.
Just add /index.html into the end of URL then it showed up and solved the case.
https://username.github.io/{repoName}/index.html
In my case, I had folders whose names started with _ (like _css and _js), which GH Pages ignores as per Jekyll processing rules. If you don't use Jekyll, the workaround is to place a file named .nojekyll in the root directory. Otherwise, you can remove the underscores from these folders
Four months ago I have contacted the support and they told me it was a problem on their side, they have temporarily fix it (for the current commit).
Today I tried again
I deleted the gh-pages branch on github
git push origin --delete gh-pages
I deleted the gh-pages branch on local
git branch -D gh-pages
I reinitialized git
git init
I recreated the branch on local
git branch gh-pages
I pushed the gh-pages branch to github
git push origin gh-pages
Works fine, I can finally update my files on the page.
If you haven't already, choose a Jekyll theme in your GitHub Pages settings tab. Apparently this is required even if you're not using Jekyll for your Pages site.
I had the same issue after forking a repo with a gh-pages branch. I was able to fix by simply pushing a new commit (just whitespace in index.html) to my fork's gh-pages branch.
In my case on 8/Aug/2017
if your user page is https://github.com/mgravell, you repo name must be
mgravell.github.io
under root, create a file index.html
under root, create a folder docs, create a file
CNAME under docs (note: NO extension like .txt, make sure your file
system shows extension)
gh-pages branch is optional, master branch is sufficient
more: check official docs here: https://help.github.com/articles/configuring-a-publishing-source-for-github-pages/
Just wait about ten minutes to one hour. If it still doesn't work, contact github. Usually it's the problem at their end.
But, if you're in a hurry, you can try to open by adding "?" question mark at the end of URL. It force query to search for the resource. Like this:
http://roine.github.com/p1?
In my case the browser had a previous cached version of my app. To avoid getting the cached version, access you url using a random query string:
https://{{your-username}}.github.io/{{your-repository}}?randomquery
My pages also kept 404'ing. Contacted support, and they pointed out that the url is case sensitive; solved my issue.
in my case i had to go to project settings and enable the github pages. The default is off
If you saw 404 even everything looks right, try switching https/http.
The original question has the url wrong, usually you can check repo settings and found the correct url for generated site.
However I have everything set up correctly, and the setting page said it's published, then I still saw 404.
Thanks for the comment of #Rohit Suthar (though that comment was to use https), I changed the url to http and it worked, then https worked too.
Add the following in the beginning of the index.html file
<!DOCTYPE html>
In my case in react was necessary to select the gh-pages branch:
I was facing the same issue, after trying most of the methods mentioned above I couldn't get the solution. In my case the issue of because of Github changing the name of master to main branch.
Go to Setting -> go to GitHub Pages section and change the branch to main:
to
Save it and select a theme, and the website is live.
If you are sure that your structure is correct, just push an empty commit or update the index.html file with some space, it works!
I had this exact problem with typedocs. The README.md worked but none of the actual docs generated by my doc strings displayed, I just got a 404 Github Pages screen.
To fix this, just place a empty file in your /docs directory (or wherever you generate your docs) & call it .nojekyll
To confirm, your file structure should now look like:
./docs/.nojekyll # plus all your generated docs
Push this up to your remote Github repo and your links etc should work now.
Also make sure you have selected in your Github settings:
Settings -> Github Pages -> Source -> master brach /docs folder
Depending on your doc framework, you probably have to recreate this file each time you update your docs, this is an example of using typedocs & creating the .nojekyll file each time in a package.json file:
# package.json
"scripts": {
"typedoc": "typedoc --out docs src && touch docs/.nojekyll"
},
The solution for me was to set right the homepage in package.json.
My project name is monsters-rolodex and I am publishing from console gh-pages -d build.
"homepage": "https://github.com/monsters-rolodex",
The project was built assuming it is hosted at /monsters-rolodex/.
Before it didn't work because in the homepage url I included my github username.
I got the site to work by deleting the "username.github.io" folder on my computer going through the steps again, including changing the index/html file.
My mistake (I think) is that i initially cloned "https://github.com/username/username.github.io.git" instead of https://github.com/username/username.github.io (no ".git")
In my case, all the suggestions above were correct. I had most pages working except few that were returning 404 even though the markdown files are there and they seemed correct. Here is what fixed it for me on these pages:
On one page, there were a few special characters that are not part of UTF-8 and I think that's why GitHub pages was not able to render them. Updating/removing these char and pushing a new commit fixed it.
On another page, I found that there were apostrophes ' surrounding the title, I removed them and the page content started showing fine
Another variant of this error:
I set up my first Github page after a tutorial but gave the file readme.md a - from my perspective - more meaningful name: welcome.md.
That was a fatal mistake:
We’ll use your README file as the site’s index if you don’t have an
index.md (or index.html), not dissimilar from when you browse to a
repository on GitHub.
from Publishing with GitHub Pages, now as easy as 1, 2, 3
I was then able to access my website page using the published at link specified under Repository / Settings / GitHub Pages followed by welcome.html or shorter welcome.
For some reason, the deployment of the GitHub pages stopped working today (2020-may-05). Previously I did not have any html, only md files. I tried to create an index.html and it published the page immediately. After removal of index.html, the publication keeps working.
I was following this YT video. So, when I ran the command in my terminal, it pushed the code to gh-pages branch already. Then I pushed to the master branch. It was giving me 404 error.
Then I swapped the branch to master and then again reverted to gh-pages and now the error is gone. It's pointing to the index.html even if it's not in the URL.
I bound my domain before this problem appeared. I committed and pushed the branch gh-pages and it solved my problem. New commits force jekyll to rebuild your pages.
In my case, the URL was quite long. So, I guess there is a limit. I put it to my custom subdomain and it worked.
On a private repo, when I first added and pushed my gh-pages branch to github, the settings for github pages automatically changed to indicate that the gh-pages branch would be published, but there no green or blue bar with the github.io url and no custom domain options.
It wasn't until I switched the source to master and quickly switched the source back to gh-pages that it actually updated with the green bar that contains the published url.
Your GitHub Pages is available at http://roine.github.io/p1 instead of http://roine.github.com/p1.
By the way, you can fix your project's description.
In my case it was that I had recently set up a custom domain for GitHub pages, but GitHub had forgotten my custom domain under (repo)<name>.github.io / Settings / Pages.
I added the custom domain again and then it immediately started working.
Go to settings section of your repository and choose master branch at the Source section and click save button after that refresh the page and you will be able to see the link of your page!.
I faced this problem (404) too and the root cause was my file was named INDEX.md. I was developing on Windows and my local Jekyll site worked (since Windows treats file names case insensitive by default). When pushed to Github, it didn't work. Once I renamed the INDEX.md to index.md, things worked well.

GitHub pages are not updating

I'm running into a weird issue with GitHub pages. I pushed a new commit to my personal pages page maltzj.github.io, but the new article isn't showing up there. When I execute the server locally, a post lives at localhost:4000/posts/the-price-of-inconsistent-code/. However, when I go to http://maltzj.github.io/posts/the-price-of-inconsistent-code I get a 404. I also added a new file which should live at http://maltz.github.io/test.html, but that also throws a 404.
Everything builds and runs locally. My Git repository is up to date, and there is nothing on the GitHub status page about problems with builds, so I'm at a little bit of a loss about where to go with this. How can I get my page to update with new content that I add?
For reference, the location of the repository which backs my page is http://github.com/maltzj/maltzj.github.io
None of these solutions solved it for me. The solution was to edit the index.html file in the GitHub website.
The website then updates on the web as expected.
Go to your index.html file through your site (example.github.io/index.html) and then reload the page. Then you can go back to (example.github.io) and it should have updated. You can do the same with the master.css file, etc.
If it doesn't work, try reloading (github.com/example/example.github.io/[blob/master/]index.html) instead and it will have updated.
For others, also check the dates of your posts. I just had this problem. I'm at UTC+11 and I'm pretty sure the server is at UTC. Thus if I date my posts with my local time, the server thinks they are in the future and won't build them. Using UTC avoided this for me.
As mentioned by joao cenoura in the comments below:
you can tell jekyll to show "future" posts by adding future: true to your _config.yml
and/or add timezone: TIMEZONE to specify your timezone.
See https://jekyllrb.com/docs/configuration/ for more info.
I had an empty CNAME file. Check that if you're having a similar issue.
I had this fault today with a static page - the cause was actually a service failure at GitHub Pages itself. You can check for service messages at https://www.githubstatus.com/.
I had the problem of having an unverified email. The update worked for the first time, but it failed after that. A verified email is needed to trigger a GitHub pages build. Also a deploy key cannot be used for this, as it won't trigger a build.
Source: http://web.archive.org/web/20140712011932/https://help.github.com/articles/troubleshooting-github-pages-build-failures/
Disclaimer: this was the case in 2014. Don't know if it's still required.
I had an unclosed <a> tag which caused the build to be pending forever. Fixing that solved the issue.
It makes sense that GitHub would verify your links.
I got it to work.
Mine was a simple problem. It was a browser cache problem.
I opened my link on a different browser and it showed me the updated push.
In my case, none of above solutions works. Finally I find out the reason is: there is "relative_permalinks" option in my _config.yml. This option is recently deprecated in Jekyll 3.0.
Refer to:
https://help.github.com/articles/removing-relative-permalinks/
I know this might sound simple, but make certain you are on the right branch and in the right file.
In my case, I made a GitHub page and tried to commit from my local repository on the master branch. Also, I was updating my filename instead of index.html. These were my errors. I had to switch to the GitHub page branch and update in the index.html commit, push and then everything worked fine.
For me, I just waited ~5 minutes, and it was updated.
If someone has made the branch gh-pages from scratch (manually) the problem is that you need a file call params.json to make it work.
I don't have this params.json file, but it still works...
In my case, it happened to be that I mentioned a relative path to refer to an image, something like - ./test.png.
It seems that it's not allowed, and it may be a security issue or what. Whatever, if you've done something like that, remove it and refer to it as test.png.
In my case the problem was because of my repository was private. After I made it public, the problem has gone.
The weird part of story is that I was able to create private repository and use GitHub pages with it. I did it in accordance with the official guide (http://take.ms/p2SS7). It worked fine for about 9 commits, but on the 10-th it became broken.
I ran into the same mysterious issue today. I pushed some new code to my github.io-repository, but the changes did not show up on the corresponding webpage. I inspected the page and did not see the new code in the source. I solved the issue by doing a hard reload. On Chrome, you can do a hard reload by opening up Dev Tools and right-clicking on the refresh-button and choosing Hard Reload.
Please refer to the Jekyll troubleshooting website, as there are multiple error sources: Troubleshooting Jekyll build errors for GitHub Pages sites
In my case a German umlaut ("ö") in a Markdown file caused the problem.
In my case, I forgot to define kramdown in _config.yaml
# Build settings
markdown: kramdown
This was caused when I was converting from a theme without to a theme with the kramdown requirement.
Make sure your run
npm run deploy
Clear your browser cache.
In my case, after trial and error on some solutions here, what fixed it was adding the encoding to the _config file like this
encoding: UTF-8
More troubleshooting options here
For me it was an issue with not properly having a .gitmodules file.
I was able to troubleshoot in the settings tab of my repository, under the GitHub pages section, which indicates build issues and was helpful for troubleshooting.
Oddly (and simply) enough I created a new branch, made that branch the "default" branch and pushed from there.
This worked for me.
My GitHub Pages was turned off under the Settings tab of the repository.
I don't remember turning it off, but there it was, and turning it back on was the fix.
In the repository settings, make sure the GitHub Pages is currently being built from the gh-pages branch.
In my case, my problem was after git push my GitHub file was updating but not showing my website on GitHub pages.
Note: I was creating Website by React
Also, on the HTML project, I faced the same problem. In that case, I just did first of all git pull and then git status | git add . | git commit -m"adding some content" | and git push. It worked for me.
But in the React project, it didn't work. I run this again on my cmd npm run deploy then my React web application is showing on GitHub pages.
My suggestion is to try everything showing on this post comments. Because the solution to this problem is not one.
In my case I left an empty parameter, url, in _config.yaml.
After I've specified url: example.github.io everything started to work.
I had this problem this week and no solution worked.
I don't use Jekyll, only pure static HTML.
It just sat three days refusing to update.
Here is what I had to do to get it to publish again.
Make a snapshot branch from master.
Reset the master branch to the last commit that is live. (Commits tab, green checkmarks indicate published commits)
Make a new commit with a smoke test. I made an HTML comment I could grep.
Force push master.
Check results curl https://example.com | grep SMOKETEST
Reset master again, removing the smoke test.
Cherry-pick each commit from the snapshot branch you need to get your unpublished changes back into master (cherry-picking gives the commits new ids/hashes, avoiding the risk of anything having cached them from before).
Force push master again.
Now you should get green checkmarks and published updates.
Note: It could be enough to force push to remove the commits that are stuck and getting them back again. The smoke test is almost certainly not required. Cherry-picking may not be required.
Github doesn't publish to github pages for me if I edit and commit files directly on github web site.
However, if I edit file locally and commit with GitHub Desktop, then change is published to site within seconds.
BTW, my email is verified, so this shouldn't be an issue. And I'm using same account.
Solution worked for me for an app created using create-react-app :
Go to GitHub Pages section under repository settings
Change source from gh-pages branch to master branch
Wait and check your custom domain website, should show master branch README.md file
Now change the source back to gh-pages
Wait couple minutes, now latest changes reflected on custom domain website
I had tried different solutions, none worked. Like a new commit, an empty commit, browser cache clear, wait for 5 - 10 minutes, delete gh-pages branch and push again, edit CNAME, create a new CNAME under on master branch etc
Note: My app has no _config.yaml file, no jekyll. I'm using custom domain with https (google domains). gh-page branch auto created by package.json script deploy: "gh-pages -d deploy"
In my case, I had made a couple of changes in the index.html and style.css files but those changes were not reflecting on the Github pages. But when I updated the Readme file by adding one line the Page got updated.
Maybe you can try this, as it might work for you just like it did for me.
If you are deploying some simple HTML codes, try this:
First, go to Actions > Deploy static content to Page:
Then, click the Run workflow:
My site failed to deploy today because of a transient failure in the GitHub Pages deploy actions. The action needed to be re-run through the Actions tab for the new version of my site to appear.
The story:
I pushed new content, on a site that's purely static and doesn't use Jekyll. After many fruitless Shift-Ctrl-R reloads on Chrome, I decided to investigate. I first visited Settings→Pages for the site’s repository, and saw that no recent deploy had taken place.
Why not, I wondered? After double-checking that my push had really gone through, I clicked the word “deployed”, and was taken to a GitHub Action that had failed!
Since the error message ECONNRESET looked like a generic network error internal to GitHub’s network, and not any problem with my site, I clicked the “Re-run” button in the upper right and asked GitHub Actions to re-run the failed task. Within a few seconds it had been re-tried and had succeeded!
Lessons:
Deploys are vulnerable to transient errors.
Deploys these days happen as normal GitHub Actions that you can inspect.
The deploys can be re-tried.

Why my blog with Jekyll Bootstrap not update?

I push it several hours ago, but my blog didn't changed yet.
Does github.com server delay or my personal reason? It test will in my computer with localhost:4000.
PS: So, I delete the repo and recreate the repo in github, but 404 always:-(
Are you accessing the page via username.github.com, or at a personal domain?
If it's at a personal domain, make sure you have a CNAME file (with that name) in the foot of the repo. It should just contain this: www.myfancydomain.com. Check your DNS settings as well.
If you're using any plugins, GitHub won't run them during generation. That could be causing a problem?
Also make sure the pushed site is in the gh-pages branch. Always good to check the basics. :)

How to fix HTTP 404 on Github Pages?

Here is my GitHub repository on the gh-pages branch.
Everything looks good, I have my index.html, my CSS, JS and pictures folders.
But when I access http://roine.github.com/p1 I get HTTP 404 not found.
Any explanation and solution?
I had just one commit with all my files. I pushed an empty commit, refreshed the page and it worked.
git commit --allow-empty -m "Trigger rebuild"
git push
If this doesn't work, as #Hendrikto pointed out in the comments, check out the Github status page and make sure GitHub Pages are operational.
I did all the tricks on my repo to fix page 404 on Github Page (https://eq19.github.io/) but it kept 404'ing.
Finaly found that my browser hardly keep the 10 minutes cache before it up on the web.
Just add /index.html into the end of URL then it showed up and solved the case.
https://username.github.io/{repoName}/index.html
In my case, I had folders whose names started with _ (like _css and _js), which GH Pages ignores as per Jekyll processing rules. If you don't use Jekyll, the workaround is to place a file named .nojekyll in the root directory. Otherwise, you can remove the underscores from these folders
Four months ago I have contacted the support and they told me it was a problem on their side, they have temporarily fix it (for the current commit).
Today I tried again
I deleted the gh-pages branch on github
git push origin --delete gh-pages
I deleted the gh-pages branch on local
git branch -D gh-pages
I reinitialized git
git init
I recreated the branch on local
git branch gh-pages
I pushed the gh-pages branch to github
git push origin gh-pages
Works fine, I can finally update my files on the page.
If you haven't already, choose a Jekyll theme in your GitHub Pages settings tab. Apparently this is required even if you're not using Jekyll for your Pages site.
I had the same issue after forking a repo with a gh-pages branch. I was able to fix by simply pushing a new commit (just whitespace in index.html) to my fork's gh-pages branch.
In my case on 8/Aug/2017
if your user page is https://github.com/mgravell, you repo name must be
mgravell.github.io
under root, create a file index.html
under root, create a folder docs, create a file
CNAME under docs (note: NO extension like .txt, make sure your file
system shows extension)
gh-pages branch is optional, master branch is sufficient
more: check official docs here: https://help.github.com/articles/configuring-a-publishing-source-for-github-pages/
Just wait about ten minutes to one hour. If it still doesn't work, contact github. Usually it's the problem at their end.
But, if you're in a hurry, you can try to open by adding "?" question mark at the end of URL. It force query to search for the resource. Like this:
http://roine.github.com/p1?
In my case the browser had a previous cached version of my app. To avoid getting the cached version, access you url using a random query string:
https://{{your-username}}.github.io/{{your-repository}}?randomquery
My pages also kept 404'ing. Contacted support, and they pointed out that the url is case sensitive; solved my issue.
in my case i had to go to project settings and enable the github pages. The default is off
If you saw 404 even everything looks right, try switching https/http.
The original question has the url wrong, usually you can check repo settings and found the correct url for generated site.
However I have everything set up correctly, and the setting page said it's published, then I still saw 404.
Thanks for the comment of #Rohit Suthar (though that comment was to use https), I changed the url to http and it worked, then https worked too.
Add the following in the beginning of the index.html file
<!DOCTYPE html>
In my case in react was necessary to select the gh-pages branch:
I was facing the same issue, after trying most of the methods mentioned above I couldn't get the solution. In my case the issue of because of Github changing the name of master to main branch.
Go to Setting -> go to GitHub Pages section and change the branch to main:
to
Save it and select a theme, and the website is live.
If you are sure that your structure is correct, just push an empty commit or update the index.html file with some space, it works!
I had this exact problem with typedocs. The README.md worked but none of the actual docs generated by my doc strings displayed, I just got a 404 Github Pages screen.
To fix this, just place a empty file in your /docs directory (or wherever you generate your docs) & call it .nojekyll
To confirm, your file structure should now look like:
./docs/.nojekyll # plus all your generated docs
Push this up to your remote Github repo and your links etc should work now.
Also make sure you have selected in your Github settings:
Settings -> Github Pages -> Source -> master brach /docs folder
Depending on your doc framework, you probably have to recreate this file each time you update your docs, this is an example of using typedocs & creating the .nojekyll file each time in a package.json file:
# package.json
"scripts": {
"typedoc": "typedoc --out docs src && touch docs/.nojekyll"
},
The solution for me was to set right the homepage in package.json.
My project name is monsters-rolodex and I am publishing from console gh-pages -d build.
"homepage": "https://github.com/monsters-rolodex",
The project was built assuming it is hosted at /monsters-rolodex/.
Before it didn't work because in the homepage url I included my github username.
I got the site to work by deleting the "username.github.io" folder on my computer going through the steps again, including changing the index/html file.
My mistake (I think) is that i initially cloned "https://github.com/username/username.github.io.git" instead of https://github.com/username/username.github.io (no ".git")
In my case, all the suggestions above were correct. I had most pages working except few that were returning 404 even though the markdown files are there and they seemed correct. Here is what fixed it for me on these pages:
On one page, there were a few special characters that are not part of UTF-8 and I think that's why GitHub pages was not able to render them. Updating/removing these char and pushing a new commit fixed it.
On another page, I found that there were apostrophes ' surrounding the title, I removed them and the page content started showing fine
Another variant of this error:
I set up my first Github page after a tutorial but gave the file readme.md a - from my perspective - more meaningful name: welcome.md.
That was a fatal mistake:
We’ll use your README file as the site’s index if you don’t have an
index.md (or index.html), not dissimilar from when you browse to a
repository on GitHub.
from Publishing with GitHub Pages, now as easy as 1, 2, 3
I was then able to access my website page using the published at link specified under Repository / Settings / GitHub Pages followed by welcome.html or shorter welcome.
For some reason, the deployment of the GitHub pages stopped working today (2020-may-05). Previously I did not have any html, only md files. I tried to create an index.html and it published the page immediately. After removal of index.html, the publication keeps working.
I was following this YT video. So, when I ran the command in my terminal, it pushed the code to gh-pages branch already. Then I pushed to the master branch. It was giving me 404 error.
Then I swapped the branch to master and then again reverted to gh-pages and now the error is gone. It's pointing to the index.html even if it's not in the URL.
I bound my domain before this problem appeared. I committed and pushed the branch gh-pages and it solved my problem. New commits force jekyll to rebuild your pages.
In my case, the URL was quite long. So, I guess there is a limit. I put it to my custom subdomain and it worked.
On a private repo, when I first added and pushed my gh-pages branch to github, the settings for github pages automatically changed to indicate that the gh-pages branch would be published, but there no green or blue bar with the github.io url and no custom domain options.
It wasn't until I switched the source to master and quickly switched the source back to gh-pages that it actually updated with the green bar that contains the published url.
Your GitHub Pages is available at http://roine.github.io/p1 instead of http://roine.github.com/p1.
By the way, you can fix your project's description.
In my case it was that I had recently set up a custom domain for GitHub pages, but GitHub had forgotten my custom domain under (repo)<name>.github.io / Settings / Pages.
I added the custom domain again and then it immediately started working.
Go to settings section of your repository and choose master branch at the Source section and click save button after that refresh the page and you will be able to see the link of your page!.
I faced this problem (404) too and the root cause was my file was named INDEX.md. I was developing on Windows and my local Jekyll site worked (since Windows treats file names case insensitive by default). When pushed to Github, it didn't work. Once I renamed the INDEX.md to index.md, things worked well.