google / addlicense

A program which ensures source code files have copyright license headers by scanning directory patterns recursively
Apache License 2.0
716 stars 169 forks source link

Fix ignore on Windows #157

Open 06393993 opened 2 months ago

06393993 commented 2 months ago

fileMatches will receive paths with native path separators(i.e. \ on Windows). Per the doc doublestar.Match doesn't work as expected with \, and filepath.ToSlash() should be used to handle such case.