Skip to content

Commit 7d00b83

Browse files
committed
Fix checkSketchCasing to work with .pde files too
1 parent 8de0dec commit 7d00b83

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Diff for: arduino/sketch/sketch.go

+5-1
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,11 @@ func (s *Sketch) checkSketchCasing() error {
226226
}
227227
files.FilterOutDirs()
228228

229-
files.FilterPrefix(s.Name)
229+
candidateFileNames := []string{}
230+
for ext := range globals.MainFileValidExtensions {
231+
candidateFileNames = append(candidateFileNames, fmt.Sprintf("%s%s", s.Name, ext))
232+
}
233+
files.FilterPrefix(candidateFileNames...)
230234

231235
if files.Len() == 0 {
232236
sketchFile := s.FullPath.Join(s.Name + globals.MainFileValidExtension)

0 commit comments

Comments
 (0)