Skip to content

Commit de46d4c

Browse files
authored
Add syntax highlighting to CSV and TSV files (#7738)
1 parent 8b6fc8a commit de46d4c

6 files changed

Lines changed: 35 additions & 3 deletions

File tree

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -686,6 +686,9 @@
686686
[submodule "vendor/grammars/language-dircolors"]
687687
path = vendor/grammars/language-dircolors
688688
url = https://github.com/jolkdarr/language-dircolors
689+
[submodule "vendor/grammars/language-dsv"]
690+
path = vendor/grammars/language-dsv
691+
url = https://github.com/Alhadis/language-dsv.git
689692
[submodule "vendor/grammars/language-emacs-lisp"]
690693
path = vendor/grammars/language-emacs-lisp
691694
url = https://github.com/Alhadis/language-emacs-lisp

grammars.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -562,6 +562,10 @@ vendor/grammars/language-debian:
562562
- source.debian.makefile
563563
vendor/grammars/language-dircolors:
564564
- source.dircolors
565+
vendor/grammars/language-dsv:
566+
- source.csv
567+
- source.dsv
568+
- source.tsv
565569
vendor/grammars/language-emacs-lisp:
566570
- source.emacs.lisp
567571
- source.yasnippet

lib/linguist/languages.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -991,7 +991,7 @@ CSV:
991991
type: data
992992
color: "#237346"
993993
ace_mode: csv
994-
tm_scope: none
994+
tm_scope: source.csv
995995
extensions:
996996
- ".csv"
997997
language_id: 51
@@ -7663,7 +7663,7 @@ TSV:
76637663
type: data
76647664
color: "#237346"
76657665
ace_mode: tsv
7666-
tm_scope: source.generic-db
7666+
tm_scope: source.tsv
76677667
extensions:
76687668
- ".tsv"
76697669
- ".vcf"

vendor/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ This is a list of grammars that Linguist selects to provide syntax highlighting
9393
- **COLLADA:** [textmate/xml.tmbundle](https://github.com/textmate/xml.tmbundle)
9494
- **CSON:** [atom/language-coffee-script](https://github.com/atom/language-coffee-script)
9595
- **CSS:** [tree-sitter/tree-sitter-css](https://github.com/tree-sitter/tree-sitter-css) 🐌
96+
- **CSV:** [Alhadis/language-dsv](https://github.com/Alhadis/language-dsv)
9697
- **CUE:** [cue-sh/vscode-cue](https://github.com/cue-sh/vscode-cue)
9798
- **Cabal Config:** [atom-haskell/language-haskell](https://github.com/atom-haskell/language-haskell)
9899
- **Caddyfile:** [caddyserver/vscode-caddyfile](https://github.com/caddyserver/vscode-caddyfile)
@@ -614,7 +615,7 @@ This is a list of grammars that Linguist selects to provide syntax highlighting
614615
- **TLA:** [tlaplus-community/tree-sitter-tlaplus](https://github.com/tlaplus-community/tree-sitter-tlaplus) 🐌
615616
- **TOML:** [textmate/toml.tmbundle](https://github.com/textmate/toml.tmbundle)
616617
- **TSQL:** [beau-witter/language-tsql](https://github.com/beau-witter/language-tsql)
617-
- **TSV:** [Alhadis/language-etc](https://github.com/Alhadis/language-etc)
618+
- **TSV:** [Alhadis/language-dsv](https://github.com/Alhadis/language-dsv)
618619
- **TSX:** [Microsoft/TypeScript-TmLanguage](https://github.com/Microsoft/TypeScript-TmLanguage)
619620
- **TXL:** [MikeHoffert/Sublime-Text-TXL-syntax](https://github.com/MikeHoffert/Sublime-Text-TXL-syntax)
620621
- **Tact:** [tact-lang/tact-sublime](https://github.com/tact-lang/tact-sublime)

vendor/grammars/language-dsv

Submodule language-dsv added at 06d46d9
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
name: language-dsv
3+
version: 06d46d933831e2120cca9ffd756b7445dc67adc9
4+
type: git_submodule
5+
homepage: https://github.com/Alhadis/language-dsv.git
6+
license: isc
7+
licenses:
8+
- sources: LICENSE.md
9+
text: |
10+
Copyright (c) 2025-2026, John Gardner
11+
12+
Permission to use, copy, modify, and/or distribute this software for any
13+
purpose with or without fee is hereby granted, provided that the above
14+
copyright notice and this permission notice appear in all copies.
15+
16+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
17+
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
18+
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
19+
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
20+
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
21+
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
22+
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
23+
notices: []

0 commit comments

Comments
 (0)