Hcl2mdtable
Generate a markdown table from terraform variable in hcl format
Install / Use
/learn @hassenius/Hcl2mdtableREADME
hcl to markdown table generator
Generates a python table from hcl variables.
Useful for documenting Terraform variable files in markdown format
Prerequisits
pip install pyhcl
example usage
with an input like this
variable "datacenter" {
description = "Data center to provision in"
default = "ams03"
}
variable "key_name" {
description = "Name or reference of SSH key to provision softlayer instances with"
default = ""
}
variable "servers" {
description = "Number of servers to provision"
}
Doing this $ python hcl2mdt.py variables.tf
will give you that
| Variable | Default | Required | Description |
|------------|---------|----------|--------------------------------------------------------------------|
| datacenter | ams03 | No | Data center to provision in |
| servers | | Yes | Number of servers to provision |
| key_name | "" | Yes | Name or reference of SSH key to provision softlayer instances with |
which Github parses like this
| Variable | Default | Required | Description | |------------|---------|----------|--------------------------------------------------------------------| | datacenter | ams03 | No | Data center to provision in | | servers | | Yes | Number of servers to provision | | key_name | "" | Yes | Name or reference of SSH key to provision softlayer instances with |
if you wish to specify a default for blank values you can do this $ python hcl2mdt.py variables.tf n/a and it will insert n/a in any place where there is no default value
Related Skills
node-connect
349.9kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
109.8kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
349.9kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
349.9kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
