{
    "$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",
    "name": "OxenteScript",
    "scopeName": "source.oxentescript",
    "patterns": [
        {
            "include": "#comments"
        },
        {
            "include": "#strings"
        },
        {
            "include": "#numbers"
        },
        {
            "include": "#keywords-baiano"
        },
        {
            "include": "#keywords-brasileiro"
        },
        {
            "include": "#operators"
        },
        {
            "include": "#functions"
        },
        {
            "include": "#punctuation"
        }
    ],
    "repository": {
        "comments": {
            "patterns": [
                {
                    "name": "comment.line.double-slash.oxentescript",
                    "match": "//.*$"
                },
                {
                    "name": "comment.block.oxentescript",
                    "begin": "/\\*",
                    "end": "\\*/"
                }
            ]
        },
        "strings": {
            "patterns": [
                {
                    "name": "string.quoted.double.oxentescript",
                    "begin": "\"",
                    "end": "\"",
                    "patterns": [
                        {
                            "name": "constant.character.escape.oxentescript",
                            "match": "\\\\."
                        }
                    ]
                },
                {
                    "name": "string.quoted.single.oxentescript",
                    "begin": "'",
                    "end": "'",
                    "patterns": [
                        {
                            "name": "constant.character.escape.oxentescript",
                            "match": "\\\\."
                        }
                    ]
                }
            ]
        },
        "numbers": {
            "patterns": [
                {
                    "name": "constant.numeric.decimal.oxentescript",
                    "match": "\\b\\d+(\\.\\d+)?([eE][+-]?\\d+)?\\b"
                },
                {
                    "name": "constant.numeric.hex.oxentescript",
                    "match": "\\b0[xX][0-9a-fA-F]+\\b"
                },
                {
                    "name": "constant.numeric.binary.oxentescript",
                    "match": "\\b0[bB][01]+\\b"
                }
            ]
        },
        "keywords-baiano": {
            "patterns": [
                {
                    "name": "keyword.control.baiano.oxentescript",
                    "match": "\\b(bora|massa|falaai|seliga|senao|laele|oxe|volta)\\b"
                }
            ]
        },
        "keywords-brasileiro": {
            "patterns": [
                {
                    "name": "keyword.control.brasileiro.oxentescript",
                    "match": "\\b(botaAí|botaAi|éIssoMemo|issoMemo|tantoFaz|fazAí|fazAi|tomaEssa|seLiga|oxente|repeteco|ateQuando|fazLogo|naCalma|seguraAí|seguraAi|meteBronca|segurei|jogueiFora)\\b"
                }
            ]
        },
        "operators": {
            "patterns": [
                {
                    "name": "keyword.operator.coloquial.oxentescript",
                    "match": "\\b(somaLogo|tiraAí|tiraAi|multiplica|parteMeio)\\b"
                },
                {
                    "name": "keyword.operator.arithmetic.oxentescript",
                    "match": "[+\\-*/%]"
                },
                {
                    "name": "keyword.operator.comparison.oxentescript",
                    "match": "(==|!=|<=|>=|<|>)"
                },
                {
                    "name": "keyword.operator.logical.oxentescript",
                    "match": "(&&|\\|\\||!)"
                },
                {
                    "name": "keyword.operator.assignment.oxentescript",
                    "match": "(=|\\+=|\\-=|\\*=|/=|%=)"
                }
            ]
        },
        "functions": {
            "patterns": [
                {
                    "name": "entity.name.function.oxentescript",
                    "match": "\\b[a-zA-Z_][a-zA-Z0-9_]*(?=\\s*\\()"
                }
            ]
        },
        "punctuation": {
            "patterns": [
                {
                    "name": "punctuation.definition.block.oxentescript",
                    "match": "[{}]"
                },
                {
                    "name": "punctuation.definition.parameters.oxentescript",
                    "match": "[()]"
                },
                {
                    "name": "punctuation.definition.array.oxentescript",
                    "match": "[\\[\\]]"
                },
                {
                    "name": "punctuation.separator.oxentescript",
                    "match": "[,;]"
                }
            ]
        }
    }
} 