diff --git a/data/core/syntax.lua b/data/core/syntax.lua index 977983c1..6fe8984a 100644 --- a/data/core/syntax.lua +++ b/data/core/syntax.lua @@ -44,7 +44,7 @@ local function find(string, field) end function syntax.get(filename, header) - return find(filename, "files") + return find(common.basename(filename), "files") or (header and find(header, "headers")) or plain_text_syntax end