Skip to content

Commit 1885cdc

Browse files
committed
Refine compatible search
1 parent a2f01e5 commit 1885cdc

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

utils/utils.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ func GetCompatibleWith(name string) map[string][]firmware {
4141
knownBoards["mkr1000"] = combo{match: "(WINC1500)*(3a0)", loader: "WINC1500/Firmware*"}
4242
knownBoards["mkrwifi1010"] = combo{match: "(NINA)", loader: "NINA/Firmware*(mkrwifi)*", avoid: "uno"}
4343
knownBoards["mkrvidor4000"] = combo{match: "(NINA)", loader: "NINA/Firmware*(mkrvidor)*", avoid: "uno"}
44-
knownBoards["uno2018"] = combo{match: "(NINA)", loader: "NINA/Firmware*(unowifi)*", prefer: "uno"}
44+
knownBoards["uno2018"] = combo{match: "(NINA)", loader: "NINA/Firmware*(unowifi)*", prefer: "uno", avoid: "mkr"}
4545
knownBoards["mkrnb1500"] = combo{match: "SARA", loader: "SARA/SerialSARAPassthrough*"}
4646

4747
listAll := false
@@ -65,6 +65,9 @@ func GetCompatibleWith(name string) map[string][]firmware {
6565
Name: fancyName,
6666
IsLoader: loader.MatchString(path) && !listAll,
6767
}
68+
if info.IsDir() {
69+
return nil
70+
}
6871
folder := filepath.Dir(path)
6972
lowerPath, _ := filepath.Rel(root, path)
7073
lowerPath = strings.ToLower(lowerPath)

0 commit comments

Comments
 (0)