From 98623b33d7d7d1e62db5aaa2d77966caa9a62e2b Mon Sep 17 00:00:00 2001 From: tolga-akyazi Date: Tue, 6 Sep 2022 12:45:56 +0200 Subject: [PATCH] combined tf docs with gomarkdoc in Makefile --- Makefile | 2 +- README.md | 42 +++++++++++++++++++++++++++++++ examples/full/.terraform-docs.yml | 11 +++++--- 3 files changed, 51 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 2ffb675..1e8b3bf 100644 --- a/Makefile +++ b/Makefile @@ -10,4 +10,4 @@ build: go build ./... generate: - gomarkdoc -u -o README.md ./commercelayer/ \ No newline at end of file + gomarkdoc -u -o README.md ./commercelayer/ && cd examples/full && terraform-docs . diff --git a/README.md b/README.md index 59f762d..db238d7 100644 --- a/README.md +++ b/README.md @@ -214,3 +214,45 @@ func stringRef(val interface{}) *string Generated by [gomarkdoc]() + + +## Requirements + +| Name | Version | +|------|---------| +| [commercelayer](#requirement\_commercelayer) | >= 0.0.1 | + +## Providers + +| Name | Version | +|------|---------| +| [commercelayer](#provider\_commercelayer) | >= 0.0.1 | + +## Modules + +No modules. + +## Resources + +| Name | Type | +|------|------| +| [commercelayer_address.example-address](https://registry.terraform.io/providers/incentro-dc/commercelayer/latest/docs/resources/address) | resource | +| [commercelayer_address.incentro-address2](https://registry.terraform.io/providers/incentro-dc/commercelayer/latest/docs/resources/address) | resource | +| [commercelayer_address.incentro-address3](https://registry.terraform.io/providers/incentro-dc/commercelayer/latest/docs/resources/address) | resource | +| [commercelayer_address.incentro_address](https://registry.terraform.io/providers/incentro-dc/commercelayer/latest/docs/resources/address) | resource | +| [commercelayer_customer_group.incentro_customer_group](https://registry.terraform.io/providers/incentro-dc/commercelayer/latest/docs/resources/customer_group) | resource | +| [commercelayer_price_list.incentro_price_list](https://registry.terraform.io/providers/incentro-dc/commercelayer/latest/docs/resources/price_list) | resource | + +## Inputs + +| Name | Description | Type | Default | Required | +|------|-------------|------|---------|:--------:| +| [api\_endpoint](#input\_api\_endpoint) | n/a | `string` | n/a | yes | +| [auth\_endpoint](#input\_auth\_endpoint) | n/a | `string` | n/a | yes | +| [client\_id](#input\_client\_id) | n/a | `string` | n/a | yes | +| [client\_secret](#input\_client\_secret) | n/a | `string` | n/a | yes | + +## Outputs + +No outputs. + \ No newline at end of file diff --git a/examples/full/.terraform-docs.yml b/examples/full/.terraform-docs.yml index 8a001a4..7d3d469 100644 --- a/examples/full/.terraform-docs.yml +++ b/examples/full/.terraform-docs.yml @@ -1,4 +1,4 @@ -formatter: "markdown table" +formatter: "markdown" # this is required version: "" @@ -13,13 +13,18 @@ sections: hide: [] show: [] + hide-all: false # deprecated in v0.13.0, removed in v0.15.0 + show-all: true # deprecated in v0.13.0, removed in v0.15.0 + content: "" output: file: "../../README.md" - mode: replace + mode: inject template: |- + {{ .Content }} + output-values: enabled: false @@ -27,7 +32,7 @@ output-values: sort: enabled: true - by: required + by: name settings: anchor: true