Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
loreanvictor committed Dec 17, 2023
1 parent 811edb5 commit 0ff7f3b
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,20 @@ git clone https://github.com/john/my-project
> [!NOTE]
> After you read a variable such as `project_name`, in any file you update or copy, `{{ tmplr.project_name }}` will be replaced with the value read. If a variable is not resolved, then `tmplr` will leave it untouched.
> [!IMPORTANT]
> Make sure any template variable you use starts with `tmplr.` prefix. tmplr will ignore any variable that doesn't.
>
> ```yaml
> # ❌ this is wrong, and `{{ project_name }}` will remain untouched
> project:
> name: {{ project_name }}
> ```
> ```yaml
> # ✅ this is correct. `{{ tmplr.project_name }}` will be replaced by the value read by the recipe.
> project:
> name: {{ tmplr.project_name }}
>```
<br>
We have multiple _commands_ and _expressions_ used in the example recipe above:
Expand Down

0 comments on commit 0ff7f3b

Please sign in to comment.