Skip to content

Commit f7a699a

Browse files
Refactor main.py: Expand TEXT_LIKE_MIME_TYPES with additional MIME types for improved text detection
1 parent 60cc71a commit f7a699a

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

extliner/main.py

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,21 @@
1919
"application/x-yaml",
2020
"application/atom+xml",
2121
"application/rss+xml",
22-
"application/x-msdos-program",
23-
"application/pgp-keys"
22+
"application/pgp-keys",
23+
"application/ecmascript", # Like JavaScript
24+
"application/sql", # SQL code
25+
"application/x-sh", # Shell scripts
26+
"application/x-python", # Python scripts
27+
"application/x-perl", # Perl scripts
28+
"application/x-php", # PHP code
29+
"application/x-latex", # LaTeX documents
30+
"application/x-troff", # manpage source
31+
"application/x-markdown", # Markdown files
32+
"application/ld+json", # JSON-LD
33+
"application/vnd.api+json", # API JSON (used in REST)
34+
"application/x-ndjson", # Newline-delimited JSON
35+
"application/x-httpd-php", # PHP source
36+
"application/x-msdos-program"
2437

2538
}
2639

0 commit comments

Comments
 (0)