Skip to content

Getting started

cgebken edited this page Dec 19, 2017 · 20 revisions

Before you can write your blogpost and get started, you need to follow these steps:

Only once:

  1. Fork the epages-devblog repository.
  2. Clone the repository.
$ git clone git@github.com:ePages-de/epages-devblog.git
  1. Install Docker for Mac or for Windows.

Everytime you write a blog post:

  1. Name your file according to the following structure: YYYY-MM-DD-the-title-of-your-post.md
    For example: 2017-09-12-five-compelling-reasons-why-you-should-care-about-terminology.md
    Note: Use the date, the post will be published, NOT the date you start writing.

  2. Store your file in /posts/2017/.

  3. Enter the folder

$ cd epages-devblog

4a. Run the folder with $ docker-compose up.
--> Using this virtual machine, you do not have to install Ruby, Jekyll or anything else yourself.

If Docker doesn't work and it's not yet opened, enter

$ docker-compose up -d

If Docker is already open, just enter:

$ docker-compose exec --privileged jekyll rake test
$ docker-compose down

Go to http://localhost:4000/ to preview your blogpost. To speed everything up, only the blog post of the previous and the current month were built.

4b. If you do not work in Docker, run

$ jekyll serve

to render your post. If you already edited the date in the front matter according to the future publication date, you need to run

$ jekyll serve --future

in order to see your post.

  1. Check if your post passes all tests by using
$ rake test

If you only want to check single parts of your post, you can use one of the following commands:

To check links or the HTML site, use

$ rake test_html

To check the front matter, use

$ rake test_posts

To check your file name, use

$ rake test_files
  1. After your post passed all tests, make a pull request on the master branch.
Clone this wiki locally