mirror of
https://github.com/kubevela/kubevela.git
synced 2026-05-16 22:37:16 +00:00
1) Fix the issue when there are more than one traitdefinitions 2) Refine README 3) lowercase workload metadata.name so it could be used as dns
24 lines
484 B
Go
24 lines
484 B
Go
package util
|
|
|
|
import (
|
|
"fmt"
|
|
"io"
|
|
"os"
|
|
)
|
|
|
|
// IOStreams provides the standard names for iostreams. This is useful for embedding and for unit testing.
|
|
// Inconsistent and different names make it hard to read and review code
|
|
type IOStreams struct {
|
|
// In think, os.Stdin
|
|
In io.Reader
|
|
// Out think, os.Stdout
|
|
Out io.Writer
|
|
// ErrOut think, os.Stderr
|
|
ErrOut io.Writer
|
|
}
|
|
|
|
func PrintErrorMessage(errorMessage string, exitCode int) {
|
|
fmt.Println(errorMessage)
|
|
os.Exit(exitCode)
|
|
}
|