mirror of
https://github.com/hashicorp/setup-terraform.git
synced 2025-12-27 13:33:37 +00:00
Update README.md example to fix escaping issues.
Sometimes (on later versions of terraform) terraform will output warnings regarding templating which include the ${} pattern. In a template, the contents are interpreted as js which will almost always fail.
This commit is contained in:
parent
4c5048fbaf
commit
08d2b8ab4b
1 changed files with 15 additions and 5 deletions
14
README.md
14
README.md
|
|
@ -113,14 +113,24 @@ steps:
|
||||||
with:
|
with:
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
script: |
|
script: |
|
||||||
|
const validate = ${{ toJson(steps.validate.outputs.stdout) }};
|
||||||
|
const plan = ${{ toJson(steps.plan.outputs.stdout) }};
|
||||||
|
|
||||||
const output = `#### Terraform Format and Style 🖌\`${{ steps.fmt.outcome }}\`
|
const output = `#### Terraform Format and Style 🖌\`${{ steps.fmt.outcome }}\`
|
||||||
#### Terraform Initialization ⚙️\`${{ steps.init.outcome }}\`
|
#### Terraform Initialization ⚙️\`${{ steps.init.outcome }}\`
|
||||||
#### Terraform Validation 🤖${{ steps.validate.outputs.stdout }}
|
#### Terraform Validation 🤖\`${{ steps.validate.outcome }}\`
|
||||||
|
|
||||||
|
<details><summary>Show Validation</summary>
|
||||||
|
|
||||||
|
\`\`\`${validate}\`\`\`
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
#### Terraform Plan 📖\`${{ steps.plan.outcome }}\`
|
#### Terraform Plan 📖\`${{ steps.plan.outcome }}\`
|
||||||
|
|
||||||
<details><summary>Show Plan</summary>
|
<details><summary>Show Plan</summary>
|
||||||
|
|
||||||
\`\`\`${process.env.PLAN}\`\`\`
|
\`\`\`terraform\n${plan}\`\`\`
|
||||||
|
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue