Table of contents

Quick Start

PHPoole is a CLI application that merges plain text files (written in Markdown), images and Twig templates to generate a static website.


Download phpoole.phar from your terminal:

curl -SOL

You can also download it from the website.

Then, you can install phpoole globally:

mv phpoole.phar /usr/local/bin/phpoole
chmod +x /usr/local/bin/phpoole

PHP 7.1+ is required.

Create a new website

phpoole new <mywebsite>


Configuration is stored in a YAML file named phpoole.yml.

└─ phpoole.yml


    title: PHPoole
    baseline: An easy and lightweight static website generator.
    description: Lorem ipsum dolor sit amet, consectetur adipiscing elit.
    language: en

Pages and sections

Pages are Markdown files organized in sections.

└─ content
   ├─ blog             <- A Section named "Blog"
   |  ├─     <- A Page in the "Blog" section
   |  └─     <- Another Page in the "Blog" Section
   ├─ project          <- A Section named "Project"
   |  └─  <- A Page in the "Project" Section
   └─         <- A Page in the root

Templates and theming

Layouts are Twig templates.

├─ content
├─ layouts
|  ├─ _default           <- Contains default templates
|  |  ├─ list.html.twig  <- Used by a "list" node type
|  |  └─ page.html.twig  <- Used by the "page" node type
|  └─ index.html.twig    <- Used by the "homepage" node type
└─ themes
   └─ <theme>            <- Custom theme
      ├─ layouts
      └─ ...

Static (public) files

Static files must be stored in the static directory: they are copied as is at the root of the built website.

├─ content
├─ layouts
└─ static
   ├─ robots.txt
   └─ style
      └─ main.css


To build and serve the website, just run the following command from the root of your project:

phpoole serve

serve command run a local HTTP server and a watcher: if a file (page, layout or config) is modified, the browser current page is reloaded.


To build only, run:

phpoole build


By default, the static website is built in the _site directory and can be published as is.


├─ blog
|  ├─ post-1
|  |  └─ index.html
|  ├─ post-2
|  |  └─ index.html
|  └─ index.html
├─ project
|  ├─ project-1
|  |  └─ index.html
|  └─ index.html
├─ about
|  └─ index.hml
├─ index.html
└─ robots.txt
Suggest a modification Next