Skip to main content

Python bindings for Hashicorp HCL2 Go library

Project description

pygohcl

Python wrapper for hashicorp/hcl (v2).

Requirements

The following versions are supported - 3.6, 3.7, 3.8.

Setup

pip install pygohcl

Usage

>>> import pygohcl
>>> pygohcl.loads("""variable "docker_ports" {
...   type = list(object({
...     internal = number
...     external = number
...     protocol = string
...   }))
...   default = [
...     {
...       internal = 8300
...       external = 8300
...       protocol = "tcp"
...     }
...   ]
... }""")
{'variable': {'docker_ports': {'default': [{'external': 8300, 'internal': 8300, 'protocol': 'tcp'}], 'type': 'list(object({internal=numberexternal=numberprotocol=string}))'}}}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

pygohcl-1.0.0rc4-cp38-cp38-manylinux1_x86_64.whl (3.0 MB view hashes)

Uploaded CPython 3.8

pygohcl-1.0.0rc4-cp37-cp37m-manylinux1_x86_64.whl (3.0 MB view hashes)

Uploaded CPython 3.7m

pygohcl-1.0.0rc4-cp36-cp36m-manylinux1_x86_64.whl (3.0 MB view hashes)

Uploaded CPython 3.6m

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page