Update Dependencies (#390)
Co-authored-by: Norwin Roosen <git@nroo.de> Co-authored-by: Norwin <git@nroo.de> Reviewed-on: https://gitea.com/gitea/tea/pulls/390 Reviewed-by: 6543 <6543@obermui.de> Reviewed-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Norwin <noerw@noreply.gitea.io> Co-committed-by: Norwin <noerw@noreply.gitea.io>
This commit is contained in:
14
vendor/github.com/alecthomas/chroma/lexers/t/toml.go
generated
vendored
14
vendor/github.com/alecthomas/chroma/lexers/t/toml.go
generated
vendored
@@ -5,14 +5,18 @@ import (
|
||||
"github.com/alecthomas/chroma/lexers/internal"
|
||||
)
|
||||
|
||||
var TOML = internal.Register(MustNewLexer(
|
||||
var TOML = internal.Register(MustNewLazyLexer(
|
||||
&Config{
|
||||
Name: "TOML",
|
||||
Aliases: []string{"toml"},
|
||||
Filenames: []string{"*.toml"},
|
||||
MimeTypes: []string{"text/x-toml"},
|
||||
},
|
||||
Rules{
|
||||
tomlRules,
|
||||
))
|
||||
|
||||
func tomlRules() Rules {
|
||||
return Rules{
|
||||
"root": {
|
||||
{`\s+`, Text, nil},
|
||||
{`#.*`, Comment, nil},
|
||||
@@ -23,7 +27,7 @@ var TOML = internal.Register(MustNewLexer(
|
||||
{`"(\\\\|\\"|[^"])*"`, StringDouble, nil},
|
||||
{`'(\\\\|\\'|[^'])*'`, StringSingle, nil},
|
||||
{`[.,=\[\]{}]`, Punctuation, nil},
|
||||
{`[^\W\d]\w*`, NameOther, nil},
|
||||
{`[A-Za-z0-9_-]+`, NameOther, nil},
|
||||
},
|
||||
},
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user