Browse Source

Support UF2 drives with space in their name on Linux

Some devices, such as Seeed Studio XIAO with Adafruit bootloader, use complex names for UF2 device. With this fix applied, /proc/mounts should be parsed correctly
pull/4268/head
Mateusz Nowak 7 months ago
committed by Ayke
parent
commit
c78dbcd3f2
  1. 5
      main.go

5
main.go

@ -1033,9 +1033,10 @@ func findFATMounts(options *compileopts.Options) ([]mountPoint, error) {
if fstype != "vfat" {
continue
}
fspath := strings.ReplaceAll(fields[1], "\\040", " ")
points = append(points, mountPoint{
name: filepath.Base(fields[1]),
path: fields[1],
name: filepath.Base(fspath),
path: fspath,
})
}
return points, nil

Loading…
Cancel
Save