Function
maxPluginCommandNameLength
(plugins map[string]pluginconfig.PluginMetadata, maxNameLen int)
Source from the content-addressed store, hash-verified
| 417 | } |
| 418 | |
| 419 | func maxPluginCommandNameLength(plugins map[string]pluginconfig.PluginMetadata, maxNameLen int) int { |
| 420 | for _, pluginMetadata := range plugins { |
| 421 | for _, cmd := range pluginMetadata.Commands { |
| 422 | if nameLen := utf8.RuneCountInString(cmd.Name); nameLen > maxNameLen { |
| 423 | maxNameLen = nameLen |
| 424 | } |
| 425 | } |
| 426 | } |
| 427 | |
| 428 | return maxNameLen |
| 429 | } |
Tested by
no test coverage detected