Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improving the Regex expressions #10

Merged
merged 1 commit into from
Jun 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
7 changes: 3 additions & 4 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,11 @@
# GitHub uses Linguist to enable language detection: https://github.com/github-linguist/linguist/
# Guide at https://dev.to/cicirello/configuring-githubs-linguist-to-improve-repository-language-reporting-295b on how to override

# .sublime.color-scheme files are JSON files. But Linguist languages.yaml doesn't seem to recognize it.
# .tmPreferences are XML files.
# .sublime.color-scheme files are JSON files. But Linguist languages.yaml doesn't seem to recognize it, and .tmPreferences are XML files.
*.sublime-color-scheme linguist-language=json
# Both JSON and XML languages are Data languages which are disabled by default. So make them linguist-detectable.
*.sublime-color-scheme linguist-detectable
*.tmPreferences linguist-detectable
# Exlude sample codes.
/samples/* linguist-documentation

/samples/* linguist-documentation
*.md linguist-documentation
2 changes: 1 addition & 1 deletion color-schemes/Mariana.sublime-color-scheme
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
{
"name": "Level 3 keys",
"scope": "meta.mapping.value meta.mapping.value meta.mapping.key string",
"foreground": "var(blue6)"
"foreground": "var(white3)"
},
{
"name": "Level 4 keys",
Expand Down
11 changes: 6 additions & 5 deletions samples/nesting-test.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"Level 1 Key A": "Level 1 Value",
"Level 1 Key B": true,
"Super long strinnnnnnnnnnnnnnnnng": true,
"Level 1 Key C": 420,
"Level 1 Key Object": {
"Level 2 key A": "Level 2 Value",
"Level 2 key B": false,
"Level 2 key C": 69,
"Level 2 key Object": {
"node_modules/@babel/code-frame": false,
"Level 2 key Obje": 69,
"level_2 key Object": {
"Level 3 key A": "Level 3 Value",
"Level 3 key B": true,
"Level 3 key C": 1337,
Expand Down Expand Up @@ -37,5 +37,6 @@
}
}
}
}
},
"Level 1 Key E": "Level 1 Value"
}
2 changes: 1 addition & 1 deletion symbols/JSON Symbols L1.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/$0/g;
s/(?&lt;=^.{20}).*/…/;
</string>
</dict>
</dict>
Expand Down
3 changes: 2 additions & 1 deletion symbols/JSON Symbols L2.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/ $0/g;
s/(?&lt;=^.{20}).*/…/;
s// /;
</string>
</dict>
</dict>
Expand Down
3 changes: 2 additions & 1 deletion symbols/JSON Symbols L3.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/ $0/g;
s/(?&lt;=^.{20}).*/…/;
s// /;
</string>
</dict>
</dict>
Expand Down
3 changes: 2 additions & 1 deletion symbols/JSON Symbols L4.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/ $0/g;
s/(?&lt;=^.{20}).*/…/;
s// /;
</string>
</dict>
</dict>
Expand Down
3 changes: 2 additions & 1 deletion symbols/JSON Symbols L5.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/ $0/g;
s/(?&lt;=^.{20}).*/…/;
s// /;
</string>
</dict>
</dict>
Expand Down
3 changes: 2 additions & 1 deletion symbols/JSON Symbols L6.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/ $0/g;
s/(?&lt;=^.{20}).*/…/;
s// /;
</string>
</dict>
</dict>
Expand Down
3 changes: 2 additions & 1 deletion symbols/JSON Symbols L7.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/ $0/g;
s/(?&lt;=^.{20}).*/…/;
s// /;
</string>
</dict>
</dict>
Expand Down
3 changes: 2 additions & 1 deletion symbols/JSON Symbols L8.tmPreferences
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
<string>1</string>
<key>symbolTransformation</key>
<string>
s/([0-9A-Za-z_ ])+/ $0/g;
s/(?&lt;=^.{20}).*/…/;
s// /;
</string>
</dict>
</dict>
Expand Down