Writing a Jenkins Pipeline: Difference between revisions
Jump to navigation
Jump to search
Line 10: | Line 10: | ||
<syntaxhighlight lang='groovy'> | <syntaxhighlight lang='groovy'> | ||
def | def versionFile = stage.readFile("${stage.WORKSPACE}/terraform/my-module/VERSION") | ||
</syntaxhighlight> | </syntaxhighlight> |
Revision as of 01:21, 21 November 2019
Internal
Recipes
- read-file step. Reading a file from the workspace: https://jenkins.io/doc/pipeline/steps/workflow-basic-steps/#readfile-read-file-from-workspace
def versionFile = stage.readFile("${stage.WORKSPACE}/terraform/my-module/VERSION")