cmd: allow more than one config yaml for build

according to the documentation the following command is valid:
`linuxkit build equinixmetal.yml equinixmetal.arm64.yml`
(docs/platform-equinixmetal.md)

So, make it valid.

Signed-off-by: Christoph Ostarek <christoph@zededa.com>
This commit is contained in:
Christoph Ostarek 2024-07-10 17:24:53 +02:00
parent c90f2ee8f2
commit 04dc9042cf

View File

@ -68,7 +68,7 @@ func buildCmd() *cobra.Command {
The generated image can be in one of multiple formats which can be run on various platforms. The generated image can be in one of multiple formats which can be run on various platforms.
`, `,
Example: ` linuxkit build [options] <file>[.yml]`, Example: ` linuxkit build [options] <file>[.yml]`,
Args: cobra.ExactArgs(1), Args: cobra.MinimumNArgs(1),
RunE: func(cmd *cobra.Command, args []string) error { RunE: func(cmd *cobra.Command, args []string) error {
if name == "" && outputFile == "" { if name == "" && outputFile == "" {
conf := args[len(args)-1] conf := args[len(args)-1]