custom paramters

This commit is contained in:
Niko Kivel
2021-05-10 00:12:13 +02:00
parent dd4c075f50
commit 54b2164c4e
9 changed files with 92 additions and 22 deletions

View File

@@ -54,6 +54,10 @@ func CobraRunE(cmd *cobra.Command, args []string) error {
fmt.Printf("%-20s %-18s %s\n", profile.Id.Get(), name+":TYPE", netdev.Hwaddr.Print())
fmt.Printf("%-20s %-18s %t\n", profile.Id.Get(), name+":DEFAULT", netdev.Default.PrintB())
}
for name, param := range profile.Params {
fmt.Printf("%-20s %-18s %s\n", profile.Id.Get(), name, param.Print())
}
}
} else {
fmt.Printf("%-20s %s\n", "PROFILE NAME", "COMMENT/DESCRIPTION")