Skip to content
This repository was archived by the owner on May 30, 2024. It is now read-only.

Add tests for HEREDOC patterns #842

Merged
merged 2 commits into from
Oct 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions grammars/ruby.cson.json
Original file line number Diff line number Diff line change
Expand Up @@ -1520,7 +1520,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)HTML)\\b\\1))",
"comment": "Heredoc with embedded html",
"comment": "Heredoc with embedded HTML",
"end": "(?!\\G)",
"name": "meta.embedded.block.html",
"patterns": [
Expand Down Expand Up @@ -1558,7 +1558,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)XML)\\b\\1))",
"comment": "Heredoc with embedded xml",
"comment": "Heredoc with embedded XML",
"end": "(?!\\G)",
"name": "meta.embedded.block.xml",
"patterns": [
Expand Down Expand Up @@ -1596,7 +1596,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)SQL)\\b\\1))",
"comment": "Heredoc with embedded sql",
"comment": "Heredoc with embedded SQL",
"end": "(?!\\G)",
"name": "meta.embedded.block.sql",
"patterns": [
Expand Down Expand Up @@ -1672,7 +1672,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)CSS)\\b\\1))",
"comment": "Heredoc with embedded css",
"comment": "Heredoc with embedded CSS",
"end": "(?!\\G)",
"name": "meta.embedded.block.css",
"patterns": [
Expand Down Expand Up @@ -1710,7 +1710,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)CPP)\\b\\1))",
"comment": "Heredoc with embedded c++",
"comment": "Heredoc with embedded C++",
"end": "(?!\\G)",
"name": "meta.embedded.block.cpp",
"patterns": [
Expand Down Expand Up @@ -1748,7 +1748,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)C)\\b\\1))",
"comment": "Heredoc with embedded c",
"comment": "Heredoc with embedded C",
"end": "(?!\\G)",
"name": "meta.embedded.block.c",
"patterns": [
Expand Down Expand Up @@ -1786,7 +1786,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)(?:JS|JAVASCRIPT))\\b\\1))",
"comment": "Heredoc with embedded javascript",
"comment": "Heredoc with embedded Javascript",
"end": "(?!\\G)",
"name": "meta.embedded.block.js",
"patterns": [
Expand Down Expand Up @@ -1824,7 +1824,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)JQUERY)\\b\\1))",
"comment": "Heredoc with embedded jQuery javascript",
"comment": "Heredoc with embedded jQuery Javascript",
"end": "(?!\\G)",
"name": "meta.embedded.block.js.jquery",
"patterns": [
Expand Down Expand Up @@ -1862,7 +1862,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)(?:SH|SHELL))\\b\\1))",
"comment": "Heredoc with embedded shell",
"comment": "Heredoc with embedded Shell",
"end": "(?!\\G)",
"name": "meta.embedded.block.shell",
"patterns": [
Expand Down Expand Up @@ -1900,7 +1900,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)LUA)\\b\\1))",
"comment": "Heredoc with embedded lua",
"comment": "Heredoc with embedded Lua",
"end": "(?!\\G)",
"name": "meta.embedded.block.lua",
"patterns": [
Expand Down Expand Up @@ -1938,7 +1938,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)RUBY)\\b\\1))",
"comment": "Heredoc with embedded ruby",
"comment": "Heredoc with embedded Ruby",
"end": "(?!\\G)",
"name": "meta.embedded.block.ruby",
"patterns": [
Expand Down Expand Up @@ -1976,7 +1976,7 @@
},
{
"begin": "(?=(?><<[-~]([\"'`]?)((?:[_\\w]+_|)SLIM)\\b\\1))",
"comment": "Heredoc with embedded slim",
"comment": "Heredoc with embedded Slim",
"end": "(?!\\G)",
"name": "meta.embedded.block.slim",
"patterns": [
Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,9 @@
"glob": "^10.3.7",
"mocha": "^10.2.0",
"prettier": "^3.0.3",
"typescript": "^5.2.2"
"typescript": "^5.2.2",
"vscode-oniguruma": "^2.0.1",
"vscode-textmate": "^9.0.0"
},
"dependencies": {
"vscode-languageclient": "^9.0.1"
Expand Down
Loading