 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Overview ¶
Example (Tree) ¶
package main
import (
	"os"
	"github.com/aws-cloudformation/rain/internal/cmd/tree"
	"github.com/aws-cloudformation/rain/internal/console"
)
func main() {
	os.Args = []string{
		os.Args[0],
		"../../../test/templates/success.template",
	}
	console.NoColour = true
	tree.Cmd.Execute()
}
Output: Resources: Bucket1: DependsOn: Parameters: - BucketName
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
      View Source
      
  var Cmd = &cobra.Command{ Use: "tree [template]", Short: "Find dependencies of Resources and Outputs in a local template", Long: "Find and display the dependencies between Parameters, Resources, and Outputs in a CloudFormation template.", Args: cobra.ExactArgs(1), Aliases: []string{"graph"}, DisableFlagsInUseLine: true, Run: func(cmd *cobra.Command, args []string) { fileName := args[0] t, err := parse.File(fileName) if err != nil { panic(ui.Errorf(err, "unable to parse template '%s'", fileName)) } g := graph.New(t) if dotGraph { printDot(g) } else { printGraph(g, "Parameters") printGraph(g, "Resources") printGraph(g, "Outputs") } }, }
Cmd is the tree command's entrypoint
Functions ¶
This section is empty.
Types ¶
This section is empty.
 Click to show internal directories. 
   Click to hide internal directories.