Skip to content

Commit

Permalink
Improved documentation of paths for templates and examples, in README
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivan De Marino committed Jun 23, 2022
1 parent c3ba333 commit 493f4ff
Showing 1 changed file with 15 additions and 5 deletions.
20 changes: 15 additions & 5 deletions README.md
Expand Up @@ -44,20 +44,30 @@ Otherwise, the provider developer can set an arbitrary description like this:

### Conventional Paths

The generation of missing documentation is based on a number of assumptions / conventional paths:
The generation of missing documentation is based on a number of assumptions / conventional paths.

For templates:

| Path | Description |
|-----------------------------------------------------------|----------------------------------------|
| `templates/` | Root of templated docs |
| `templates/index.md[.tmpl]` | Docs index page (or template) |
| `examples/provider/provider.tf` | Provider example config* |
| `templates/data-sources.md[.tmpl]` | Generic data source page (or template) |
| `templates/data-sources/<data source name>.md[.tmpl]` | Data source page (or template) |
| `examples/data-sources/<data source name>/data-source.tf` | Data source example config* |
| `templates/resources.md[.tmpl]` | Generic resource page (or template) |
| `templates/resources/<resource name>.md[.tmpl]` | Resource page (or template) |
| `examples/resources/<resource name>/resource.tf` | Resource example config* |
| `examples/resources/<resource name>/import.sh` | Resource example import command |

Note: the `.tmpl` extension is necessary, for the file to be correctly handled as a template.

For examples:

| Path | Description |
|-----------------------------------------------------------|---------------------------------|
| `examples/` | Root of examples |
| `examples/provider/provider.tf` | Provider example config |
| `examples/data-sources/<data source name>/data-source.tf` | Data source example config |
| `examples/resources/<resource name>/resource.tf` | Resource example config |
| `examples/resources/<resource name>/import.sh` | Resource example import command |

### Templates

Expand Down

0 comments on commit 493f4ff

Please sign in to comment.