Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Dec 12, 2023. It is now read-only.

Add sprig template funcions collection (#45)#52

Merged
wtschreiter merged 1 commit intomasterfrom
feature/add-support-for-sprig-template-funcions
Jun 22, 2020
Merged

Add sprig template funcions collection (#45)#52
wtschreiter merged 1 commit intomasterfrom
feature/add-support-for-sprig-template-funcions

Conversation

@wtschreiter
Copy link
Contributor

  • Add support for sprig template functions
    • THIS IS A BREAKING CHANGE FOR THE indent FUNCTION
    • indent no longer accepts []byte input. Only string input is accepted.
    • indent no longer trimes input.
    • indent no longer inserts two spaces per indent but one space.
    • Required migration steps
      • you need to double the indent size
        • indent 4 "hallo world" needs to be indent 8 "hallo world"
      • if you read file content and use indent you need to use readAsString
        • {{read "input-file.txt" | indent 4 }} needs to be {{readAsString "input-file.txt" | indent 8 }}
      • if you need to remove surrounding whitespaces you need to do it explicit using trim
        • indent 4 " hallo world " needs to be trim " hallo world " | indent 8

Closes #45

@wtschreiter wtschreiter requested a review from mmueller90 May 2, 2020 16:00
@wtschreiter wtschreiter self-assigned this May 2, 2020
@wtschreiter wtschreiter force-pushed the feature/add-support-for-sprig-template-funcions branch from c58460f to 09a9d0c Compare May 24, 2020 16:05
Copy link
Contributor

@mmueller90 mmueller90 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks fine from my side.

@wtschreiter wtschreiter force-pushed the feature/add-support-for-sprig-template-funcions branch from 09a9d0c to a3a75df Compare June 22, 2020 06:18
@wtschreiter wtschreiter merged commit 0997b72 into master Jun 22, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] add sprig template function support

2 participants

Comments