Skip to content

Custom jinja plugins #23

@jayvdb

Description

@jayvdb

Sort of related to #18 ..

while moban providing some extra built-in filters/tests might be helpful, it would be even more helpful if moban loaded filters/tests from the moban yaml configuration, and even loaded custom globals for greater convenience.

e.g.

- plugin_dirs:
  - /path/to/.moban-py
- plugins:
  - jinja_globals:
    - load_file.py
  - jinja_filters:
    - strip_blank_lines.py
  - jinja_tests:
    - file_exists.py

where .moban-py/file_exists.py would provide the functionality needed for #18 , and

.moban-py/load_file.py and .moban-py/strip_blank_lines.py would allow

{{ set var = load_file('foo') | strip_blank_lines }}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions