Skip to content

[feature] Indexing #119

@ryan-ph

Description

@ryan-ph

Currently there is no support for indexing on a list. Ideally we should be able to query and write to specific objects within a list. For example, if we have the following HCL file:

# attrs.tf
attribute = ["str1", "str2", "str3"]

I would expect the following query to work and return the following result:

$ hcledit read -o go-template="{{.Value}}" "attribute[1]" attrs.tf
str2

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions