I created a simple jekyll site as https://github.com/nagachinta/nagachinta.github.io, but throws 404 error. I observed the git commits I made and the commits in the git says.
" A file was included in about.md that is a symlink , doesnot exist in your '_includes', directory."
The file is not a symlink, it's just a real file.
The index files , etc are real files not symlinks.
You're using Jekyll 3.2 locally. This means that you're now using gem based themes. No more _includes, _layouts and _sass folder when you do your jekyll new.
On the other side github pages uses Jekyll 3.1.6 (reference).
So when you pull a site created without _includes, _layouts and _sass folders on github pages, it results in build errors. Your site is not created and you get 404s errors.
If you want to be sure that a site developed locally to work on github pages, you can go with gh-pages gems. See install instructions here.
If you just want to stay with jekyll 3.2 locally and copy themes's files, you can have a look at this answer.
Related
I have a GitHub Pages site that I generated by creating a repository and choosing a theme on GitHub. While the site is technically built using Jekyll, it has no gemfile, and the _config.yml is very concise:
theme: jekyll-theme-dinky
title: "<site name>"
In contrast, proper Jekyll sites created with jekyll new . have proper gemfile and gemfile.lock files, and a verbose _config.yml. Pardon my general ignorance with Jekyll and Ruby, but I assume these are necessary for Jekyll to build the site locally.
Running jekyll serve on a local clone of my site doesn't build the site properly. Yet GitHub's own pipeline can.
The question: Is there a way to locally build and preview my site without adding a gemfile/gemfile.lock and changing _config.yml? I.e. do exactly what GitHub's pipeline does, just on my computer.
I have a jekyll site that I want to deploy as github-pages. It works fine standalone but fails to build within github-pages with the include error from _index.html. I don't even have an _include directory. I am using the minimal-mistakes theme. I have slimmed down my site to the bare bones it can be found at https://github.com/laredo/mm-jekyll
The exact error is: A file was included in index.html that is a symlink or does not exist in your _includes directory.
https://github.com/laredo/mm-jekyll/blob/master/index.html
Looking for suggestions to successfully build the site
In your _config.yml
delete theme: minimal-mistakes-jekyll
add remote_theme: mmistakes/minimal-mistakes
enable jekyll-include-cache in the plugins configuration
Plugins config is now :
plugins:
- jekyll-feed
- jekyll-include-cache
I have a blog based on Jekyll and Minimal Mistakes. It's already hosted in github-pages. I don't know how you started your project, but what worked to me was just clone the minimal mistakes Github repository and change the _config.yml.
i have a mixed situation where i have my custom website generated in a _dev folder, and i want jekyll generated blog files to go in that same folder. of course i don't want jekyll to wipe up any of the files that are already there, but just to wipe up and rebuild the jekyll related files.
i don't want to list all the things i want to keep like this:
keep_files: [js,css,images,*.html]
plus the *.html, while building, throws an error. is there a way to tell jekyll to just wipe up and rebuild the jekyll related files only?
i can't find many options on this on the official documentation.
i'm on jekyll 3.4.3
By default Jekyll deletes the output folder before building the site. Unless you change that behaviour in source code you can build your website in a temporal folder and copy the contents replacing the old files in your website folder.
jekyll build --destination /tmp/jk
cp -r /tmp/jk/* _dev/
This way it will only replace the Jekyll related files.
How can I bypass jekyll compilation at GitHub and push _site folder (after local compilation) and host there.
If you don't want github page to process you site with Jekyll, you can add an empty .nojekyll file at the root of your generated code. See mojombo post.
There is nothing special to do; just use your _site folder as the content for you github pages.
You can't bypass the compilation step, but it will not modify your content.
Just try and run jekyll serve locally in your _site folder to make sure.
EDIT: #David Jacquel's answer is more accurate
I have been using Jekyll for my blog and it has been working fine. Now I am trying to add new posts from a computer running Ubuntu 14.04 and Jekyll 2.4.0. The problem is that, only on this computer, it does not generate index.html in _site.
I can't find anything in the documentation that helps, and in any event, I'm using git so I have the same configuration on all of my machines.
So the question is: How does one turn off generation of index.html in Jekyll, and how can it be turned back on?
[Update: I did gem uninstall jekyll followed by gem install jekyll, rebuilt the site, and everything works fine. The original install must not have completed properly.]
To turn generation off you can remove this file. Or to use static index.html file remove markdown section enclosed with double triple --- in header (in this case static index.html will be parsed). Also mention filename it in exclude: section of _config.yml to avoid copying to _site folder.