Skip to content

template variables #30

@joereynolds

Description

@joereynolds

These would make templates a lot more useful.
atm they're quite limited.

Two ways of doing this I can think of

1 Simple pre-defined functions

{{ today}} # today's date
{{ user }} # user on machine
{{ note }} # name of the note

2 call bash (or other shells)

Maybe shelling out would be acceptable and we could do stuff like

{{ date +%Y }} # just passes "date +%Y" shell and evaluates the result

Pros to this are it's as flexible as you want it to be
Cons are it's a bit gnarly in the template and crafting the commands could be fiddly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions