added language detection by filename strategy

This commit is contained in:
Manuel Carmona
2017-04-19 10:59:34 +02:00
parent 645bdd7331
commit df60eab1ad
3 changed files with 42 additions and 1 deletions

View File

@ -48,7 +48,7 @@ func main() {
return nil
}
l := slinguist.GetLanguage(path, content)
l := slinguist.GetLanguage(filepath.Base(path), content)
r, err := filepath.Rel(root, path)
if err != nil {