Skip to content

Latest commit

 

History

History
36 lines (25 loc) · 1.52 KB

File metadata and controls

36 lines (25 loc) · 1.52 KB

YAML merge

Overview

This command line tool enables merging yaml files into one single file. For the operation to work, the yaml files must follow the same source path. For example, the following command allows the tool to merge the component configurations residing under the /prow/cluster/components path and place the resulting target file under /prow/cluster/starter.yaml.

go run main.go -path /prow/cluster/components -target /prow/cluster/starter.yaml

NOTE: If the starter.yaml file does not already exist under a given path, it will be created.

Usage

For security reasons, the dry-run mode is the default one. To run it, use:

go run main.go -path /path/to/components/folder -target /path/to/target/file

To turn the dry-run mode off, use:

go run main.go -path /path/to/components/folder -target /path/to/target/file -dryRun=false

Flags

See the list of available flags:

Name Required Description
--path Yes Path to the folder containing the yaml files to merge.
--target Yes Path of the file which includes the content of the merged files.
--dryRun No The boolean value that controls the dry-run mode. Its default value is true.