Allow to enumerate distro types
This commit is contained in:
parent
7040fb7a0b
commit
e91af205f4
4
main.go
4
main.go
@ -93,8 +93,10 @@ const (
|
||||
Debian
|
||||
)
|
||||
|
||||
var distroTypeStrings = [...]string{"Ubuntu", "CentOS", "Debian"}
|
||||
|
||||
func (dt distroType) String() string {
|
||||
return [...]string{"Ubuntu", "CentOS", "Debian"}[dt]
|
||||
return distroTypeStrings[dt]
|
||||
}
|
||||
|
||||
func (dt *distroType) UnmarshalTOML(data []byte) (err error) {
|
||||
|
Loading…
Reference in New Issue
Block a user