Why is it that i am getting a 404 on Github when trying to publish a site on Git Hubs platform - github

Below is the website that i created thru GitHub.
I followed a tutorial to get here , the tutorial advised me to wait 30 mins for the server to clear up.
and it didn't what should i do now?
Below is the link to the site
https://wildcardpossibiliites.github.io/cv/
Sincerely

Just checked your repo at https://github.com/WildCardPossibiliites/cv
The problem is your repo doesn't include a index.html file but Index.html.
If you replace it to index.html, it will be fixed. Otherwise, you can see the intended page at https://wildcardpossibiliites.github.io/cv/Index.html

Related

Jekyll/Github site does not show correct sample blog post on Github

I am running Windows 10 with GitHub Desktop. I installed Jekyll and tried to create a test blog.
I started with the instructions at:
https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll/creating-a-github-pages-site-with-jekyll
I created the repository in GitHub Desktop and immediately published it to Github.com.
When I use GitHub Desktop to "open in bash" as mentioned in the link above, I get sent to:
E:\codingPractice\DocSourceBlog\DocSourceBlog>
Following the suggestions in the link above, I enter:
E:\codingPractice\DocSourceBlog\DocSourceBlog>mkdir docs
E:\codingPractice\DocSourceBlog\DocSourceBlog>cd docs
E:\codingPractice\DocSourceBlog\DocSourceBlog\docs>git checkout --orphan gh-pages
I enter $ jekyll new . and I get
New jekyll site installed in E:/codingPractice/DocSourceBlog/DocSourceBlog/docs.
I edit the gemfile, comment out the "gem jekyll" and change the next line to
gem "github-pages", "~> 214", group: :jekyll_plugins
by substituting the current version number into the boilerplate of the above link.
I run bundle update and bundle exec jekyll serve and localhost:4000 shows the expected site, including a sample blog post that can be accessed by clicking "Welcome of Jekyll!" That sample blog post starts off with:
You’ll find this post in your _posts directory. Go ahead and edit it and re-build the site to see your changes. You can rebuild the site in many different ways,
I use GitHub Desktop to commit the changed files to the branch and publish the branch to GitHub.
I refer to instructions at:
https://docs.github.com/en/pages/getting-started-with-github-pages/configuring-a-publishing-source-for-your-github-pages-site#choosing-a-publishing-source
I go to github.com/longarchivist/DocSourceBlog/settings/pages and set the source to "gh-pages" and "docs"
I go to https://longarchivist.github.io/DocSourceBlog/ and see that some of the content is there, but the blog post does not seem to show up as expected at "Welcome to Jekyll!" I click the link and get to
https://longarchivist.github.io/jekyll/update/2021/04/18/welcome-to-jekyll.html
but that has the 404 page.
I check the github web interface to make sure that the "_posts" directory is there.
I noticed that the address of the "Welcome to Jekyll!" link was:
http://localhost:4000/jekyll/update/2021/04/18/welcome-to-jekyll.html
I can speculate that ruby somehow destroyed the correct Jekyll configuration when I tried bundle exec jekyll serve but if that was enough to break the system then the documentation seems to be badly misleading.
I tried editing the config file. The "baseurl" variable is now "/docs" and the link address is
https://longarchivist.github.io/docs/jekyll/update/2021/04/18/welcome-to-jekyll.html
However, the desired sample blog post still does not display. Instead
https://longarchivist.github.io/docs/jekyll/update/2021/04/18/welcome-to-jekyll.html
is still a 404 page.
So the localhost problem is not the key to the problem.
Any constructive criticisms would be appreciated.
The best way seems to be to start a root directory that must contain your username first, then start a separate project directory for each project.
After creating a project directory, use "jekyll build" to auto-generate a Jekyll site. Add posts manually in the posts directory: somehow the index finds them automatically.
Then go back to the root site and manually add a link to your project directory.
For example:
https://longarchivist.github.io/
links to
https://longarchivist.github.io/codediary/
which currently has two posts. I created the second post by copying the original, then renaming it. Jekyll apparently expects the post filename to have the correct day and month, so when I use this tactic in the future, I will have to update those manually.

Why can't I host my project on github pages?

I have a simple weather app using react I've built and pushed to Github. Everything works when I run it locally but when I try to host it on Github pages, I get a 404 error.
https://caseycling.github.io/weather-app/
I'm not sure what I did wrong as I took the same steps as with every other project I've succesfully deployed: went to settings and under Github pages, I chose master branch as the source. Initially, it was just displaying the readme but now it only displays a 404 error message. When I've googled this issue, some people are saying I need to move my folders to the root of the directory but I'm not sure how to do that exactly.
Here is the repo:
https://github.com/caseycling/weather-app/
My understanding is that in order to run a react app in github pages you need to setup the gh-pages plugin and have a special 'deploy' build script in package.json
https://itnext.io/so-you-want-to-host-your-single-age-react-app-on-github-pages-a826ab01e48
https://codeburst.io/deploy-react-to-github-pages-to-create-an-amazing-website-42d8b09cd4d
https://medium.com/the-andela-way/how-to-deploy-your-react-application-to-github-pages-in-less-than-5-minutes-8c5f665a2d2a
There are also apparently certain restrictions in what you can do with the router in github pages websites, but for a simple app it should be sufficient.

Using Github to create a webpage but it returns a 404 error

Am trying to test out hosting a website from Github using Github pages.I created a skeleton website using Jekyll and uploaded it into a .github.io repository:
https://github.com/themallardcomplexion/themallardcomplexion.github.io
I then enabled github pages from the setting.
So right now if I go to: themallardcomplexion.github.io I should be able to see the Jekyll site. However all I get is a 404 error...
I know its not an index issue as I have an index.md file in my repository. I've enabled github pages so what am I doing wrong? I have tried searching for the problem online but none of the solutions seem applicable..
Thanks internet people
I deleted everything and created a new repository. Seems to be working now. Dont know what the problem was but at least its working..

Github pages returns readme file instead of index.html. Can't host my react project

I have problem with host my react project on gh-pages.
i Have my repo on github ----> GitHub repo
My page return readme file instead of indx.html (public/index.html). ---> My Page
What should i do to my page with my react app works correctly?
In my experience, it was simply a latency issue. When I initially committed index.html (in the root of the repo), myorg.github.io continued to serve README.md. After a few hours, I returned and tried it again - lo and behold my index.html was served. Because of the time I was away, I can't make a guess about how long it takes github pages to update.
I have added front matter part to the readme.md and it fixed the problem.
---
permalink: /index.html
---
After this it shows index.html instead of readme. I have found this solution also helps for custom 404 pages. https://help.github.com/articles/creating-a-custom-404-page-for-your-github-pages-site/
Yes, the problem is in how you have deployed your site, you should deploy your target index.html to gh-pages
Check this out:
https://medium.freecodecamp.com/surge-vs-github-pages-deploying-a-create-react-app-project-c0ecbf317089
It gives a detailed and pretty good explanation on how to deploy react application to github pages.

Not able to see the webpage of the github repository

I am very new to github.
I pushed my repository into github.
And in settings page, they tell my site is published at
http://jerinzam.github.io/coi-site.
But that URL gives me a 404 page.
Can someone give some xplanation on this.
And also FYI my project uses MEAN stack
Thanks in advance
You have two problems:
GitHub won't run your site. It is only for static hosting, not Node.js hosting. It also doesn't support any databases, including MongoDB.
From the project pages documentation:
The gh-pages branch is used to build and publish Project Pages sites.
You have three branches, but none of them are called gh-pages:
gh-pa
gn-pages
master
This is exactly as above.
You can host your code repo on github, but the web link to that repo will literally be whatever it is in the browser.
Now if you are wanting to run your site, then try this - https://masteringmean.com/lessons/557-Setup-and-Getting-Started-Running-Your-Site
You will need to have the mongo server running before starting the server. Check this is running by typing $mongod
so just go to the directory then type $ node run.js