why is my hugo site not building on github pages? - github-pages

So my hugo site is working on localhost and doesn't work on github pages.
My repo is at:
https://github.com/ba789/ba789.github.io

You can follow the Hugo documentation "Host on GitHub", but you would need two different repositories:
As mentioned in the GitHub Pages documentation, you can host a user/organization page in addition to project pages.
Here are the key differences in GitHub Pages websites for Users and Organizations:
You must use a <USERNAME>.github.io to host your generated content
Content from the main branch will be used to publish your GitHub Pages site
This is a much simpler setup as your Hugo files and generated content are published into two different repositories.

Related

Github Pages error

I wrote a web application on nuxt.js. I followed this instruction clearly.
Nuxt.js deploy on GitHub Pages
But when I deploy my app to Github Pages, there was an error on my site in the console
Here is my site
the .nojekyllfile is missing
You have forgotten to commit the empty file called .nojekyll from dist to your github project.
This is because GitHub Pages will by default ignore any files and folders prefixed by an underscore (like _nuxt), as documented here: https://github.com/blog/572-bypassing-jekyll-on-github-pages

Can hosted GitHub Pages websites accept file uploads?

I would like to create a simple website that accepts a text file upload for a small project that parses the text. Is this possible to do with GitHub Pages? I haven't found anything that addresses this functionality so I am wondering if it is possible or not.
As seen in this issue, there is no server side configuration or execution with GitHub Pages, so no.
The only workaround is rafrex/spa-github-pages: Single Page Apps for GitHub Pages, a lightweight solution for deploying single page apps with GitHub Pages. You can easily deploy a React single page app with React Router <BrowserRouter />.
But that might not include what you are looking for.

keep gh-pages automatically up to date

I have this project with a gh-pages branch setup.
The web content inside of it was published via gh pages generator function.
https://mh-cbon.github.io/go-msi/
It s really just the README.md to index.html + layout.
Now i would like this web content to be synced with my updates.
As a matter of fact, gh pages functionality requires to go through the github web ui to trigger the build.
Indeed, i made a test change on my readme, pushed it on master, but the published website remains the same.
See the commit
The test wording won t be find into the site
Q: how can i do to automatically triggers the rebuild of my pages ?
Ideally, with just a call to a github api.
Would like not to do a plain setup of jekyll.
If not possible, can you provide a 3 steps command way to build the pages using a free theme and the README.md of my project ?
You could use Travis CI or another CI system to do automatic updates to you gh-pages branch. This Github Gist has a complete and detailed explanation of the process. You can easily combine those instructions with these on how to restructure your index.html etc. to allow to Jekyll updates and automate everything.
I don't think that the raw Github Page Generator is available through the Github API, but I'm pretty sure that the Github Page Generator is just using Jekyll.
Only gh-pages branch content is published.
If you push to master branch this doesn't trigger the build for gh-pages branch.
If you want to update you published pages, you have to push to gh-pages.
At http://agentscript.org, which is the gh-pages site for the repo for agentscript, I simply:
Created an automatic page via github's Automatic Generator
Replaced the static readme text in index.html with html generated by the current readme
..By using a library that converts md to html.
I'm not sure if that's what you're looking for. I could supply more details if needed.
thanks to all for your contributions, I ended implementing my own solution.
Basically its a bunch of sh scripts to execute over vagrant, docker, travis etc.
For now on I provided all you need to generate, with a vagrant box or a travis yaml, your gh-pages with the cayman theme like the github service does.
It is available at https://github.com/mh-cbon/gh-pages
The generated site is here
If you want to use another theme, you will need to ensure the jekyll configuration in _config.yml is correct.
You may also need to update the template files of the selected theme, at least for cayman theme i needed to.
All those adjustments are to implement into a config.jekyll.sh file to put on the root of your repository to generate.
That's it!

Sitecore Config files for MultiSite Solution

We have a MultiSite solution using Sitecore 7.1 .
I want to use custom config files for different Sites. For example i have a different CustomLink Provider for Sites , Different 404 pages , Different Language Resolver .
How should i add or patch these config files and in what order ????
Any help
You can't have a different web.config for each site but there are techniques you can apply to make things easier:
I've written some blog posts that address just this topic:
A Switching Link Provider in Sitecore
Create Site Specific
Pipeline Processors for Sitecore
Here are some others that you may find useful:
Site-Specific Providers
Sitecore Pipeline Enabled LinkProvider
Sitecore - Multiple-Site Error Page Handling
If you do want to do this with configuration files you would have to set up multiple content delivery sites. You would then deploy different configuration files to the different environments so that they would use your custom code and configurations. Each website 'site' definition would be pointed to a different root in the common Sitecore database.
This would require a scaled model with multiple licenses. If that's not possible, I recommend going with #TwentyGotoTen's approach for supporting the multi-site within a single website.

How to publish .php page instead of .html at github to demo some php content?

I am looking at the following demo - http://blueimp.github.com/jQuery-File-Upload/
To my understanding in the demo, php files are being served from github which means php content can be served / run from github.
I understand the process to publish html content from code hosted at github via this link - http://help.github.com/pages/ I am just curious to know how can I show a .php page as a demo, similar to what is done in blueimp above.
I tried similar thing at http://synechron.github.com/index2.php but instead of displaying in the browser window the page gets downloaded in Google chrome and in IE9 index.html is displayed.
Github Pages is not a full-featured web host. It will not execute PHP, or any other arbitrary code.
No, you can’t.
Github Pages let you serve web client content (HTML, Javascript, CSS) without the need of owning and maintaining a web server. You can make sub folders, map your domain into it. Use tools such as Jekyll or Hugo with some basic programming skills, you can make your site work as good as an CMS.
However, it does not allow you to use any backend technology to process and manipulate data/logic.
So, PHP is not possible.