• Stars
    star
    190
  • Rank 202,605 (Top 5 %)
  • Language
    Python
  • License
    MIT License
  • Created about 5 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Codacy Badge Codacy Badge Build Status License PyPI Python Versions Downloads

Python HCL2

A parser for HCL2 written in Python using Lark. This parser only supports HCL2 and isn't backwards compatible with HCL v1. It can be used to parse any HCL2 config file such as Terraform.

About Amplify

Amplify builds innovative and compelling digital educational products that empower teachers and students across the country. We have a long history as the leading innovator in K-12 education - and have been described as the best tech company in education and the best education company in tech. While others try to shrink the learning experience into the technology, we use technology to expand what is possible in real classrooms with real students and teachers.

Learn more at https://www.amplify.com

Getting Started

Prerequisites

python-hcl2 requires Python 3.7 or higher to run.

Installing

This package can be installed using pip

pip3 install python-hcl2

Usage

import hcl2
with open('foo.tf', 'r') as file:
    dict = hcl2.load(file)

Building From Source

For development, tox>=4.0.9 is recommended.

Running Tests

python-hcl2 uses tox. You will need to install tox with pip install tox. Running tox will automatically execute linters as well as the unit tests.

You can also run them individually with the -e argument.

For example, tox -e py37-unit will run the unit tests for python 3.7

To see all the available options, run tox -l.

Releasing

To create a new releaes go to Releases page, press 'Draft a new release', create a tag with a version you want to be released, fill the release notes and press 'Publish release'. Github actions will take care of publishing it to PyPi.

Responsible Disclosure

If you have any security issue to report, contact project maintainers privately. You can reach us at mailto:[email protected]

Contributing

We welcome pull requests! For your pull request to be accepted smoothly, we suggest that you:

  • For any sizable change, first open a GitHub issue to discuss your idea.
  • Create a pull request. Explain why you want to make the change and what itโ€™s for.

Weโ€™ll try to answer any PRโ€™s promptly.

More Repositories

1

serverless-domain-manager

Serverless plugin for managing custom domains with API Gateways.
TypeScript
935
star
2

serverless-log-forwarding

Serverless plugin for forwarding CloudWatch logs to another Lambda function.
TypeScript
57
star
3

serverless-vpc-discovery

Serverless plugin for discovering VPC / Subnet / Security Group configuration by name.
TypeScript
38
star
4

asiaq

Python
25
star
5

honeydew

Honeydew is a Ruby driver for UIAutomator which enables automated testing of Android devices
Java
24
star
6

terrawrap

Python
16
star
7

amplium

A Python-based proxy for multiple Selenium Grid Hubs.
Python
6
star
8

rover

A tool for checking out code across heterogeneous version control repositories.
Python
6
star
9

rcubic

A framework for coordinating the execution of many loosely related scripts.
Python
6
star
10

hiccup

HTTP semantics and REST for Android ContentProviders.
Java
6
star
11

wgen-gitphp

Fork of Chris Han's GitPHP
PHP
5
star
12

astroscaler

A Python-based application for autoscaling EC2 and Spotinst groups in AWS.
Python
4
star
13

wgen-iText

Fork of iText library
Java
4
star
14

amplify_aws_utils

Collection of utilities for working with boto3
Python
2
star
15

release-path

Set of scripts for maintaining a source repository that uses branches for each release
Python
2
star
16

data_kennel

A Python CLI tool for managing Datadog infrastructure.
Python
2
star
17

ionica

Amplify's flexible sass grid
CSS
2
star
18

stashifier

A REST client for Stash, implementing a useful subset of the Stash REST API.
Python
1
star
19

filestore

Fork of JohnMacFarlane's versioning filestore library
Haskell
1
star
20

metargs

Library that allows programs to take arguments on the command line and through a configuration file and integrate them
Python
1
star
21

minirest

Python
1
star
22

simpleversions

Library that performs simple version comparison operations
Python
1
star
23

angular-promises

A wrapper for Angular's Deferred and Promise APIs
CoffeeScript
1
star
24

globetrotter

Uses public DNS servers indexed by http://public-dns.tk/ to resolve addresses worldwide
Ruby
1
star