getShortHandles returns the short hand answers for the continueation prompt
()
| 165 | |
| 166 | // getShortHandles returns the short hand answers for the continueation prompt |
| 167 | func (p InteractiveContinuePrinter) getShortHandles() []string { |
| 168 | var handles []string |
| 169 | for _, option := range p.Options { |
| 170 | handles = append(handles, strings.ToLower(string([]rune(option)[0]))) |
| 171 | } |
| 172 | handles[p.DefaultValueIndex] = strings.ToUpper(handles[p.DefaultValueIndex]) |
| 173 | |
| 174 | return handles |
| 175 | } |
| 176 | |
| 177 | // setDefaultHandles initialises the handles |
| 178 | func (p *InteractiveContinuePrinter) setDefaultHandles() { |