_sites folder does not have all resources

Hi there,

I am new to Jekyll and am trying to figure out how people deploy the _site folder. I am able to run jekyll serve and see the site with the default minima theme. However, when I run jekyll build, it doesn’t copy over folders like _layouts, _includes, etc to _site. How do I make Jekyll do this? How do you guys deploy the site? I tried disabling the Gem theme and manually copying those folders but that didn’t work either.

Thanks,
Ravi

Think you may be confused as to what Jekyll is doing when you build or serve.

It copies any static assets that aren’t _ underscore prefixed… e.g. images, JavaScript, fonts, stylesheets, etc to the _site folder.

And it generates HTML out of your _posts, _layouts, and _includes, placing them into _site. It doesn’t copy the source files there for a few reasons:

  1. They’re source files and not something you typically need to deploy.
  2. They’re in _ underscore prefixed folders which Jekyll ignores by default when copying.

Thanks, I think I figured out the issue. The html pages in _site cannot be opened using the file:// syntax for some reason, they have to be served through a HTTP server. Running python -m SimpleHTTPServer is a good way to play around with that.