@@ -18,7 +18,7 @@ package com.blacksquircle.ui.feature.editor.data.model
18
18
19
19
internal object FileAssociation {
20
20
21
- private val associations = HashMap <String , String >(72 )
21
+ private val associations = HashMap <String , String >(300 )
22
22
23
23
init {
24
24
associations[" .bat" ] = LanguageScope .BAT
@@ -32,13 +32,29 @@ internal object FileAssociation {
32
32
associations[" .clojure" ] = LanguageScope .CLOJURE
33
33
associations[" .edn" ] = LanguageScope .CLOJURE
34
34
associations[" .cpp" ] = LanguageScope .CPP
35
+ associations[" .cc" ] = LanguageScope .CPP
36
+ associations[" .cxx" ] = LanguageScope .CPP
37
+ associations[" .c++" ] = LanguageScope .CPP
35
38
associations[" .hpp" ] = LanguageScope .CPP
39
+ associations[" .hh" ] = LanguageScope .CPP
40
+ associations[" .hxx" ] = LanguageScope .CPP
41
+ associations[" .h++" ] = LanguageScope .CPP
42
+ associations[" .ii" ] = LanguageScope .CPP
36
43
associations[" .ino" ] = LanguageScope .CPP
44
+ associations[" .inl" ] = LanguageScope .CPP
45
+ associations[" .ipp" ] = LanguageScope .CPP
46
+ associations[" .ixx" ] = LanguageScope .CPP
47
+ associations[" .tpp" ] = LanguageScope .CPP
48
+ associations[" .txx" ] = LanguageScope .CPP
49
+ associations[" .in" ] = LanguageScope .CPP
37
50
associations[" .cs" ] = LanguageScope .CSHARP
51
+ associations[" .csx" ] = LanguageScope .CSHARP
52
+ associations[" .cake" ] = LanguageScope .CSHARP
38
53
associations[" .css" ] = LanguageScope .CSS
39
54
associations[" .scss" ] = LanguageScope .CSS
40
55
associations[" .dart" ] = LanguageScope .DART
41
56
associations[" .Dockerfile" ] = LanguageScope .DOCKER
57
+ associations[" .Containerfile" ] = LanguageScope .DOCKER
42
58
associations[" .f03" ] = LanguageScope .FORTRAN
43
59
associations[" .f08" ] = LanguageScope .FORTRAN
44
60
associations[" .f18" ] = LanguageScope .FORTRAN
@@ -60,56 +76,156 @@ internal object FileAssociation {
60
76
associations[" .gy" ] = LanguageScope .GROOVY
61
77
associations[" .gsh" ] = LanguageScope .GROOVY
62
78
associations[" .gradle" ] = LanguageScope .GROOVY
63
- associations[" .htm" ] = LanguageScope .HTML
79
+ associations[" .Jenkinsfile" ] = LanguageScope .GROOVY
80
+ associations[" .nf" ] = LanguageScope .GROOVY
64
81
associations[" .html" ] = LanguageScope .HTML
82
+ associations[" .htm" ] = LanguageScope .HTML
83
+ associations[" .shtml" ] = LanguageScope .HTML
84
+ associations[" .xhtml" ] = LanguageScope .HTML
85
+ associations[" .xht" ] = LanguageScope .HTML
86
+ associations[" .mdoc" ] = LanguageScope .HTML
87
+ associations[" .jsp" ] = LanguageScope .HTML
88
+ associations[" .asp" ] = LanguageScope .HTML
89
+ associations[" .aspx" ] = LanguageScope .HTML
90
+ associations[" .jshtm" ] = LanguageScope .HTML
91
+ associations[" .volt" ] = LanguageScope .HTML
92
+ associations[" .ejs" ] = LanguageScope .HTML
93
+ associations[" .rhtml" ] = LanguageScope .HTML
65
94
associations[" .ini" ] = LanguageScope .INI
95
+ associations[" .env" ] = LanguageScope .INI
96
+ associations[" .conf" ] = LanguageScope .INI
66
97
associations[" .properties" ] = LanguageScope .INI
98
+ associations[" .cfg" ] = LanguageScope .INI
99
+ associations[" .directory" ] = LanguageScope .INI
100
+ associations[" .gitattributes" ] = LanguageScope .INI
101
+ associations[" .gitconfig" ] = LanguageScope .INI
102
+ associations[" .gitmodules" ] = LanguageScope .INI
67
103
associations[" .editorconfig" ] = LanguageScope .INI
68
- associations[" .env " ] = LanguageScope .INI
104
+ associations[" .repo " ] = LanguageScope .INI
69
105
associations[" .java" ] = LanguageScope .JAVA
106
+ associations[" .jav" ] = LanguageScope .JAVA
70
107
associations[" .js" ] = LanguageScope .JAVASCRIPT
71
108
associations[" .jsx" ] = LanguageScope .JAVASCRIPT
72
109
associations[" .mjs" ] = LanguageScope .JAVASCRIPT
73
110
associations[" .cjs" ] = LanguageScope .JAVASCRIPT
111
+ associations[" .es6" ] = LanguageScope .JAVASCRIPT
112
+ associations[" .pac" ] = LanguageScope .JAVASCRIPT
74
113
associations[" .json" ] = LanguageScope .JSON
75
114
associations[" .jl" ] = LanguageScope .JULIA
76
115
associations[" .kt" ] = LanguageScope .KOTLIN
77
116
associations[" .kts" ] = LanguageScope .KOTLIN
78
117
associations[" .tex" ] = LanguageScope .LATEX
118
+ associations[" .ltx" ] = LanguageScope .LATEX
119
+ associations[" .ctx" ] = LanguageScope .LATEX
79
120
associations[" .lisp" ] = LanguageScope .LISP
80
121
associations[" .lsp" ] = LanguageScope .LISP
81
122
associations[" .cl" ] = LanguageScope .LISP
82
123
associations[" .l" ] = LanguageScope .LISP
83
124
associations[" .lua" ] = LanguageScope .LUA
84
125
associations[" .Makefile" ] = LanguageScope .MAKE
126
+ associations[" .mak" ] = LanguageScope .MAKE
127
+ associations[" .mk" ] = LanguageScope .MAKE
85
128
associations[" .md" ] = LanguageScope .MARKDOWN
129
+ associations[" .mkd" ] = LanguageScope .MARKDOWN
130
+ associations[" .mdwn" ] = LanguageScope .MARKDOWN
131
+ associations[" .mdown" ] = LanguageScope .MARKDOWN
132
+ associations[" .markdown" ] = LanguageScope .MARKDOWN
133
+ associations[" .markdn" ] = LanguageScope .MARKDOWN
134
+ associations[" .mdtxt" ] = LanguageScope .MARKDOWN
135
+ associations[" .mdtext" ] = LanguageScope .MARKDOWN
136
+ associations[" .workbook" ] = LanguageScope .MARKDOWN
86
137
associations[" .pl" ] = LanguageScope .PERL
87
138
associations[" .pm" ] = LanguageScope .PERL
88
139
associations[" .pod" ] = LanguageScope .PERL
89
140
associations[" .t" ] = LanguageScope .PERL
90
141
associations[" .psgi" ] = LanguageScope .PERL
142
+ associations[" .raku" ] = LanguageScope .PERL
143
+ associations[" .rakumod" ] = LanguageScope .PERL
144
+ associations[" .rakutest" ] = LanguageScope .PERL
145
+ associations[" .rakudoc" ] = LanguageScope .PERL
146
+ associations[" .nqp" ] = LanguageScope .PERL
147
+ associations[" .p6" ] = LanguageScope .PERL
148
+ associations[" .pl6" ] = LanguageScope .PERL
149
+ associations[" .pm6" ] = LanguageScope .PERL
91
150
associations[" .php" ] = LanguageScope .PHP
92
- associations[" .php3" ] = LanguageScope .PHP
93
151
associations[" .php4" ] = LanguageScope .PHP
94
152
associations[" .php5" ] = LanguageScope .PHP
95
- associations[" .phps" ] = LanguageScope .PHP
96
153
associations[" .phtml" ] = LanguageScope .PHP
154
+ associations[" .ctp" ] = LanguageScope .PHP
97
155
associations[" .txt" ] = LanguageScope .TEXT
98
156
associations[" .log" ] = LanguageScope .TEXT
99
157
associations[" .py" ] = LanguageScope .PYTHON
158
+ associations[" .rpy" ] = LanguageScope .PYTHON
100
159
associations[" .pyw" ] = LanguageScope .PYTHON
160
+ associations[" .cpy" ] = LanguageScope .PYTHON
161
+ associations[" .gyp" ] = LanguageScope .PYTHON
162
+ associations[" .gypi" ] = LanguageScope .PYTHON
101
163
associations[" .pyi" ] = LanguageScope .PYTHON
164
+ associations[" .ipy" ] = LanguageScope .PYTHON
165
+ associations[" .pyt" ] = LanguageScope .PYTHON
102
166
associations[" .rb" ] = LanguageScope .RUBY
167
+ associations[" .rbx" ] = LanguageScope .RUBY
168
+ associations[" .rjs" ] = LanguageScope .RUBY
169
+ associations[" .gemspec" ] = LanguageScope .RUBY
170
+ associations[" .rake" ] = LanguageScope .RUBY
171
+ associations[" .ru" ] = LanguageScope .RUBY
172
+ associations[" .erb" ] = LanguageScope .RUBY
173
+ associations[" .podspec" ] = LanguageScope .RUBY
174
+ associations[" .rbi" ] = LanguageScope .RUBY
175
+ associations[" Rakefile" ] = LanguageScope .RUBY
176
+ associations[" Gemfile" ] = LanguageScope .RUBY
177
+ associations[" Guardfile" ] = LanguageScope .RUBY
178
+ associations[" Podfile" ] = LanguageScope .RUBY
179
+ associations[" Capfile" ] = LanguageScope .RUBY
180
+ associations[" Cheffile" ] = LanguageScope .RUBY
181
+ associations[" Hobofile" ] = LanguageScope .RUBY
182
+ associations[" Vagrantfile" ] = LanguageScope .RUBY
183
+ associations[" Appraisals" ] = LanguageScope .RUBY
184
+ associations[" Rantfile" ] = LanguageScope .RUBY
185
+ associations[" Berksfile" ] = LanguageScope .RUBY
186
+ associations[" Thorfile" ] = LanguageScope .RUBY
187
+ associations[" Puppetfile" ] = LanguageScope .RUBY
188
+ associations[" Dangerfile" ] = LanguageScope .RUBY
189
+ associations[" Brewfile" ] = LanguageScope .RUBY
190
+ associations[" Fastfile" ] = LanguageScope .RUBY
191
+ associations[" Appfile" ] = LanguageScope .RUBY
192
+ associations[" Deliverfile" ] = LanguageScope .RUBY
193
+ associations[" Matchfile" ] = LanguageScope .RUBY
194
+ associations[" Scanfile" ] = LanguageScope .RUBY
195
+ associations[" Snapfile" ] = LanguageScope .RUBY
196
+ associations[" Gymfile" ] = LanguageScope .RUBY
103
197
associations[" .rs" ] = LanguageScope .RUST
104
198
associations[" .sh" ] = LanguageScope .SHELL
199
+ associations[" .bash" ] = LanguageScope .SHELL
200
+ associations[" .bashrc" ] = LanguageScope .SHELL
201
+ associations[" .bash_aliases" ] = LanguageScope .SHELL
202
+ associations[" .bash_profile" ] = LanguageScope .SHELL
203
+ associations[" .bash_login" ] = LanguageScope .SHELL
204
+ associations[" .ebuild" ] = LanguageScope .SHELL
205
+ associations[" .profile" ] = LanguageScope .SHELL
206
+ associations[" .bash_logout" ] = LanguageScope .SHELL
207
+ associations[" .xprofile" ] = LanguageScope .SHELL
208
+ associations[" .xsession" ] = LanguageScope .SHELL
209
+ associations[" .xsessionrc" ] = LanguageScope .SHELL
210
+ associations[" .zsh" ] = LanguageScope .SHELL
211
+ associations[" .zshrc" ] = LanguageScope .SHELL
212
+ associations[" .zprofile" ] = LanguageScope .SHELL
213
+ associations[" .zlogin" ] = LanguageScope .SHELL
214
+ associations[" .zlogout" ] = LanguageScope .SHELL
215
+ associations[" .zshenv" ] = LanguageScope .SHELL
216
+ associations[" .zsh-theme" ] = LanguageScope .SHELL
217
+ associations[" .fish" ] = LanguageScope .SHELL
105
218
associations[" .ksh" ] = LanguageScope .SHELL
106
- associations[" .bsh" ] = LanguageScope .SHELL
107
219
associations[" .csh" ] = LanguageScope .SHELL
220
+ associations[" .cshrc" ] = LanguageScope .SHELL
221
+ associations[" .tcshrc" ] = LanguageScope .SHELL
222
+ associations[" .yashrc" ] = LanguageScope .SHELL
223
+ associations[" .yash_profile" ] = LanguageScope .SHELL
224
+ associations[" .bsh" ] = LanguageScope .SHELL
108
225
associations[" .tcsh" ] = LanguageScope .SHELL
109
- associations[" .zsh" ] = LanguageScope .SHELL
110
- associations[" .bash" ] = LanguageScope .SHELL
111
226
associations[" .smali" ] = LanguageScope .SMALI
112
227
associations[" .sql" ] = LanguageScope .SQL
228
+ associations[" .dsql" ] = LanguageScope .SQL
113
229
associations[" .sqlite" ] = LanguageScope .SQL
114
230
associations[" .sqlite2" ] = LanguageScope .SQL
115
231
associations[" .sqlite3" ] = LanguageScope .SQL
@@ -119,16 +235,74 @@ internal object FileAssociation {
119
235
associations[" .mts" ] = LanguageScope .TYPESCRIPT
120
236
associations[" .cts" ] = LanguageScope .TYPESCRIPT
121
237
associations[" .vb" ] = LanguageScope .VISUALBASIC
238
+ associations[" .brs" ] = LanguageScope .VISUALBASIC
239
+ associations[" .vbs" ] = LanguageScope .VISUALBASIC
122
240
associations[" .bas" ] = LanguageScope .VISUALBASIC
123
- associations[" .cls" ] = LanguageScope .VISUALBASIC
124
- associations[" .xhtml" ] = LanguageScope .XML
125
- associations[" .xht" ] = LanguageScope .XML
241
+ associations[" .vba" ] = LanguageScope .VISUALBASIC
126
242
associations[" .xml" ] = LanguageScope .XML
243
+ associations[" .xsd" ] = LanguageScope .XML
244
+ associations[" .ascx" ] = LanguageScope .XML
245
+ associations[" .atom" ] = LanguageScope .XML
246
+ associations[" .axml" ] = LanguageScope .XML
247
+ associations[" .axaml" ] = LanguageScope .XML
248
+ associations[" .bpmn" ] = LanguageScope .XML
249
+ associations[" .cpt" ] = LanguageScope .XML
250
+ associations[" .csl" ] = LanguageScope .XML
251
+ associations[" .csproj" ] = LanguageScope .XML
252
+ associations[" .dita" ] = LanguageScope .XML
253
+ associations[" .ditamap" ] = LanguageScope .XML
254
+ associations[" .dtd" ] = LanguageScope .XML
255
+ associations[" .ent" ] = LanguageScope .XML
256
+ associations[" .mod" ] = LanguageScope .XML
257
+ associations[" .dtml" ] = LanguageScope .XML
258
+ associations[" .fsproj" ] = LanguageScope .XML
259
+ associations[" .fxml" ] = LanguageScope .XML
260
+ associations[" .iml" ] = LanguageScope .XML
261
+ associations[" .isml" ] = LanguageScope .XML
262
+ associations[" .jmx" ] = LanguageScope .XML
263
+ associations[" .launch" ] = LanguageScope .XML
264
+ associations[" .menu" ] = LanguageScope .XML
265
+ associations[" .mxml" ] = LanguageScope .XML
266
+ associations[" .nuspec" ] = LanguageScope .XML
267
+ associations[" .opml" ] = LanguageScope .XML
268
+ associations[" .owl" ] = LanguageScope .XML
269
+ associations[" .proj" ] = LanguageScope .XML
270
+ associations[" .props" ] = LanguageScope .XML
271
+ associations[" .pt" ] = LanguageScope .XML
272
+ associations[" .publishsettings" ] = LanguageScope .XML
273
+ associations[" .pubxml" ] = LanguageScope .XML
274
+ associations[" .rbxlx" ] = LanguageScope .XML
275
+ associations[" .rbxmx" ] = LanguageScope .XML
276
+ associations[" .rdf" ] = LanguageScope .XML
277
+ associations[" .rng" ] = LanguageScope .XML
278
+ associations[" .rss" ] = LanguageScope .XML
279
+ associations[" .shproj" ] = LanguageScope .XML
280
+ associations[" .storyboard" ] = LanguageScope .XML
281
+ associations[" .targets" ] = LanguageScope .XML
282
+ associations[" .tld" ] = LanguageScope .XML
283
+ associations[" .tmx" ] = LanguageScope .XML
284
+ associations[" .vbproj" ] = LanguageScope .XML
285
+ associations[" .vcxproj" ] = LanguageScope .XML
286
+ associations[" .wsdl" ] = LanguageScope .XML
287
+ associations[" .wxi" ] = LanguageScope .XML
288
+ associations[" .wxl" ] = LanguageScope .XML
289
+ associations[" .wxs" ] = LanguageScope .XML
127
290
associations[" .xaml" ] = LanguageScope .XML
128
- associations[" .xdf" ] = LanguageScope .XML
129
- associations[" .xmpp" ] = LanguageScope .XML
291
+ associations[" .xbl" ] = LanguageScope .XML
292
+ associations[" .xib" ] = LanguageScope .XML
293
+ associations[" .xlf" ] = LanguageScope .XML
294
+ associations[" .xliff" ] = LanguageScope .XML
295
+ associations[" .xpdl" ] = LanguageScope .XML
296
+ associations[" .xul" ] = LanguageScope .XML
297
+ associations[" .xoml" ] = LanguageScope .XML
130
298
associations[" .yaml" ] = LanguageScope .YAML
131
299
associations[" .yml" ] = LanguageScope .YAML
300
+ associations[" .eyaml" ] = LanguageScope .YAML
301
+ associations[" .eyml" ] = LanguageScope .YAML
302
+ associations[" .cff" ] = LanguageScope .YAML
303
+ associations[" .yaml-tmlanguage" ] = LanguageScope .YAML
304
+ associations[" .yaml-tmpreferences" ] = LanguageScope .YAML
305
+ associations[" .yaml-tmtheme" ] = LanguageScope .YAML
132
306
}
133
307
134
308
fun guessLanguage (extension : String ): String? {
0 commit comments