Skip to content

ConvertFrom-Hcl

SYNOPSIS

Converts an HCL string to a PowerShell object.

SYNTAX

__AllParameterSets

ConvertFrom-Hcl [-InputObject] <string> [<CommonParameters>]

ALIASES

This cmdlet has the following aliases, {{Insert list of aliases}}

DESCRIPTION

Converts a HashiCorp Configuration Language (HCL) formatted string into a PowerShell object. Supports HCL syntax as used in Terraform configuration files (.tf), variable files (.tfvars), and other infrastructure-as-code tooling.

EXAMPLES

EXAMPLE 1

ConvertFrom-Hcl -InputObject 'locals { environment = "production" }'

Converts an HCL string to a PowerShell object.

PARAMETERS

-InputObject

The HCL string to convert.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 0
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

OUTPUTS

NOTES

{{ Fill in the related links here }}