helpers

package
v0.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 7, 2025 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyIgnoreOnCodeBlock added in v0.3.1

func ApplyIgnoreOnCodeBlock(checks data.Check, indexOfCheckedcheck int, modules map[string]data.TerraformModule) (data.Check, error)

Remove the check from the list if it is ignoreed in the code

func ApplyIgnoreOnModule added in v0.3.1

func ApplyIgnoreOnModule(checks data.Check, indexOfCheckedcheck int, modules map[string]data.TerraformModule) (data.Check, error)

Remove the check from the list if it is ignoreed at the module level

func AssociateIgnoreingComments added in v0.3.1

func AssociateIgnoreingComments(ignoreCommentOfFile []data.IgnoreComment, keys []string, resourcesInFile map[string]data.TerraformCodeBlock, modules map[string]data.TerraformModule, path string)

AssociateIgnoreingComments associates the ignoreing comments to a resource (Resource, Data, Variable or Output) Not provider config

func AssociateIgnoreingCommentsOnModule added in v0.3.1

func AssociateIgnoreingCommentsOnModule(ignoreOnModule []data.IgnoreModule, path string, modules map[string]data.TerraformModule)

func CombinationsStr added in v0.2.0

func CombinationsStr(iterable []string, r int) chan []string

CombinationsStr generates all the combinations of r elements extracted from an slice of strings

func ComputeLayers

func ComputeLayers(withPlan bool) ([]*data.Layer, error)

func GenCombinations added in v0.2.0

func GenCombinations(n, r int) <-chan []int

GenCombinations generates, from two natural numbers n > r, all the possible combinations of r indexes taken from 0 to n-1. For example if n=3 and r=2, the result will be: [0,1], [0,2] and [1,2]

func GetIgnoreingComments added in v0.3.1

func GetIgnoreingComments(path string) ([]data.IgnoreComment, error)

func GetIgnoreingInFile added in v0.3.1

func GetIgnoreingInFile() ([]data.IgnoreModule, error)

func GetLayers

func GetLayers() ([]*data.Layer, error)

func GetModules

func GetModules() (map[string]data.TerraformModule, error)

func HasError added in v0.1.3

func HasError(checks []data.Check) bool

func LoadModule added in v0.2.0

func LoadModule(path string) (data.TerraformModule, error)

func RenderChecks

func RenderChecks(checkResults []data.Check, verbose bool)

func RenderTable

func RenderTable(checkResults []data.Check)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳