From b8722ce83bce727d88a61cecff3343d3046e75f7 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Fri, 9 Mar 2018 14:49:33 +0100 Subject: refactor(templater): Pass resource set path to insertFile function This is actually several refactors in one: * rename "fileContent" function to "insertFile" * pass the resource set path to the "insetFile" function * update docs and example with a pipeline including indentation adjustments for the inserted file --- docs/templates.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'docs/templates.md') diff --git a/docs/templates.md b/docs/templates.md index d9ff0fd126e3..11488f573a59 100644 --- a/docs/templates.md +++ b/docs/templates.md @@ -74,9 +74,10 @@ Some template functions come from Go's standard library and are listed in the [Go documentation][]. In addition the functions declared by [sprig][] are available in kontemplate, as well as three custom functions: -`json`: Encodes any supplied data structure as JSON. -`passLookup`: Looks up the supplied key in [pass][]. -`fromFile`: Insert the contents of the given file from the resource set folder. +* `json`: Encodes any supplied data structure as JSON. +* `passLookup`: Looks up the supplied key in [pass][]. +* `insertFile`: Insert the contents of the given file in the resource + set folder as a string. ## Examples: -- cgit 1.4.1