diff --git a/.github/templates/README.tpl b/.github/templates/README.tpl index ef183dd..43a0246 100644 --- a/.github/templates/README.tpl +++ b/.github/templates/README.tpl @@ -13,7 +13,7 @@ branch. ## Version -`{{ $version }}` (uses [terraform-docs] v0.16.0, which is supported and tested on Terraform +`{{ $version }}` (uses [terraform-docs] v0.17.0, which is supported and tested on Terraform version 0.11+ and 0.12+ but may work for others.) {{- if eq $version "main" }} diff --git a/Dockerfile b/Dockerfile index ee42485..6b863bd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -FROM quay.io/terraform-docs/terraform-docs:0.16.0 +FROM quay.io/terraform-docs/terraform-docs:0.17.0 # this is explicitly needed because yq v4.x only exists in this repo. RUN echo "http://dl-4.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories diff --git a/README.md b/README.md index bbe3fe3..b78a9d8 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ branch. ## Version -`v1.0.0` (uses [terraform-docs] v0.16.0, which is supported and tested on Terraform +`v1.0.0` (uses [terraform-docs] v0.17.0, which is supported and tested on Terraform version 0.11+ and 0.12+ but may work for others.) ### Upgrade v0 to v1 @@ -75,10 +75,10 @@ jobs: | indention | Indention level of Markdown sections [1, 2, 3, 4, 5] | `2` | false | | output-file | File in module directory where the docs should be placed | `README.md` | false | | output-format | terraform-docs format to generate content (see [all formats](https://github.com/terraform-docs/terraform-docs/blob/master/docs/FORMATS\_GUIDE.md)) (ignored if `config-file` is set) | `markdown table` | false | -| output-method | Method should be one of `replace`, `inject`, or `print` | `inject` | false | +| output-method | Method should be one of `replace`, `inject`, or `print`. Set as an empty string if `output.mode` and `output.file` are defined in config-file | `inject` | false | | recursive | If true it will update submodules recursively | `false` | false | | recursive-path | Submodules path to recursively update | `modules` | false | -| template | When provided will be used as the template if/when the `output-file` does not exist | `\n{{ .Content }}\n` | false | +| template | When provided will be used as the template if/when the `output-file` does not exist. Set as an empty string if `output.template` is defined in config-file | `\n{{ .Content }}\n` | false | | working-dir | Comma separated list of directories to generate docs for (ignored if `atlantis-file` or `find-dir` is set) | `.` | false | #### Output Method (output-method) diff --git a/src/docker-entrypoint.sh b/src/docker-entrypoint.sh index b90445b..d9a61a0 100755 --- a/src/docker-entrypoint.sh +++ b/src/docker-entrypoint.sh @@ -177,7 +177,7 @@ fi set +e num_changed=$(git_status) set -e -echo "num_changed=${num_changed}" >> $GITHUB_OUTPUT +echo "num_changed=${num_changed}" >> "$GITHUB_OUTPUT" if [ "${INPUT_GIT_PUSH}" = "true" ]; then git_commit