Packages

Content Management System for static sites, like Jekyll but with elixir/eex rather than liquid templates

Current section

Files

Jump to
dragon lib slayer.ex
Raw

lib/slayer.ex

defmodule Dragon.Slayer do
@moduledoc """
The Dragon process itself manages state, and as such does not include any
processing work. This is run from tasks external, where the actual heavy
lifting happens.
"""
def build(:all, target) do
with {:ok, dragon} <- Dragon.configure(target), do: rebuild(:all, dragon)
end
def rebuild(:all, dragon) do
with {:ok, dragon} <- Dragon.prepare_build(dragon),
{:ok, dragon} <- Dragon.Scss.Evaluate.all(dragon) do
# do Dragon Template last so prior things can be generated, allowing the
# 'path' function to properly find things
Dragon.Template.Evaluate.all(dragon)
end
end
end