mirror of
https://github.com/Hopiu/micro.git
synced 2026-03-27 03:10:24 +00:00
Merge pull request #3214 from dmaluka/filetype-autocomplete-unknown
Autocomplete `unknown` value in `set filetype ...`
This commit is contained in:
commit
d96f060b4c
1 changed files with 7 additions and 0 deletions
|
|
@ -87,6 +87,13 @@ func filetypeComplete(input string) (string, []string) {
|
|||
}
|
||||
}
|
||||
|
||||
if strings.HasPrefix("off", input) {
|
||||
suggestions = append(suggestions, "off")
|
||||
}
|
||||
if strings.HasPrefix("unknown", input) {
|
||||
suggestions = append(suggestions, "unknown")
|
||||
}
|
||||
|
||||
var chosen string
|
||||
if len(suggestions) == 1 {
|
||||
chosen = suggestions[0]
|
||||
|
|
|
|||
Loading…
Reference in a new issue