Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
27 lines (21 sloc) 630 Bytes

title: Environment

type: class

module: lektor.environment

summary: The working environment for the build process.

body:

This class holds all the relevant information for building a Lektor Project :ref. It can be reused between builds and only holds state that is immutable after initialization. For instance it will hold all loaded plugins, the configuration for the Jinja 2 template engine and more.

Plugins have access to the environment at any point by accessing self.env.

Example

from lektor.project import Project

project = Project.discover()
env = project.make_env()