Set -e # fail on error # ensure you have loaded git's environment with rbenv/ruby/jekyll in the path source /home/git/.bash_profile ![]() It's usually at /home/git/repositories/MY_REPO.git/hooks/post-receive. Run sudo su - git and find the post-receive file in your repository. You'll need to add a new user for your SSH key and create the repo for your site. ![]() Once you have gitolite installed, go back to your local machine and configure gitolite as described. Then ensure git is installed and create a new git user. Next, ensure you have a daemonized web server installed, like nginx or apache. Then ensure RubyGems is installed, and install the github-pages gem. I suggest using rbenv to keep your Rubies organized. Ruby and RubyGems with the proper permissions to install new gems.įirst, sudo su - root.A web server if you don't have one already (Apache/Nginx).I use a Rackspace CentOS 1GB Performance VM, but you can use any Linux system from any provider. Here's a step-by-step guide to making your own GitHub Pages. In fact, my personal site () is published with this method. What if you could have the same workflow – just git push – for sites with custom plugins? You could build locally and push the compiled site up to GitHub Pages, but that requires that you install all the dependencies locally and write a script to compile and jostle things in just the right way to make it all work. ![]() Either way, you need a plugin or two to get it just right. Maybe you're writing a huge website for your employer, or just something small for yourself. So what's the best way to host a Jekyll site that requires plugins? The only downside? You can't use any custom Ruby code, which means no custom plugins. ![]() You push up any valid Jekyll site to a repo (on a special branch), and it's built and published to a predictable URL. GitHub Pages is a wonderful free platform GitHub has created to build and host your Jekyll sites for you.
0 Comments
Leave a Reply. |