Skip to content

How to Build the Website

Zach Whaley edited this page Jul 28, 2016 · 16 revisions

Info

Our website uses Jekyll to build itself, then GitHub Pages Uses the built site to serve it to the world :)

Forewarning: Jekyll is only officially supported on Mac and Linux. It should work on Windows, but is not guaranteed.

How to Build the Website

1. Getting the Code

The website's code is hosted in a Git repository on GitHub.com.

To download the code you will need to install Git on your computer. GitHub has created a very useful app to use Git on your desktop. I highly recommend using it.

Now to download the code. If you have installed GitHub's desktop app, follow these instructions. If you have not installed GitHub's desktop app and want to use your computer's terminal instead, follow these instructions for Windows and these for Mac.

2. Installing Jekyll

Mac/Linux

As mentioned above, our site is built with a program called Jekyll. Before installing Jekyll, you'll need to install a program called Bundler. Bundler is a program to keep track of all the packages needed to build the website.

To install Bundler, open your terminal, copy and paste the commands below verbatim into your terminal window, and press Enter.

gem install bundler

Next, we'll use Bundler to install the rest of our website's packages.

You'll need to know where in your computer you downloaded the code for this step. I believe the GitHub desktop app can tell you where that is.

Open your terminal again. We are going to use the cd command to Change Directories (go to a different folder) to the directory(folder) where you downloaded the website code. Use the command below as a guide, but replace Documents/gpa-code/ with your code's downloaded location.

cd Documents/gpa-code/

After completing this command, run the below command.

bundle install

This last command will download all the packages, including Jekyll, required to build the website.

Windows

In progress...

See this post for now...

3. Building the Website

Open your terminal again, use the cd command again to change directories to the directory where you downloaded the website code.

Then run the below command

bundle exec jekyll serve

Some text will show up in the terminal, and in that text a URL that looks like this http://127.0.0.1:4000/

Copy and paste that URL into a browser and the website should come up!

This is not the real website, but just a copy running locally on your computer.

When you close your terminal, the website will stop running :)

Questions?

Feel free to email the website admin at [email protected]

Clone this wiki locally