(s string)
| 345 | } |
| 346 | |
| 347 | func (n *NameStyle) Set(s string) error { |
| 348 | switch s { |
| 349 | case "none": |
| 350 | *n = NameStyleNone |
| 351 | case "hash", "sha-1", "sha1": |
| 352 | *n = NameStyleHash |
| 353 | case "full": |
| 354 | *n = NameStyleFull |
| 355 | default: |
| 356 | return fmt.Errorf("not a valid name style: %v", s) |
| 357 | } |
| 358 | return nil |
| 359 | } |
| 360 | |
| 361 | func (n *NameStyle) Type() string { |
| 362 | return "nameStyle" |
no outgoing calls
no test coverage detected