language_colors 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +21 -0
- data/.gitignore +3 -0
- data/Gemfile +1 -2
- data/Gemfile.lock +6 -6
- data/README.md +7 -0
- data/Rakefile +6 -0
- data/language_colors.gemspec +2 -0
- data/lib/colors.json +97 -6
- data/lib/language_colors/version.rb +1 -1
- data/lib/language_colors.rb +6 -7
- data/lib/linguist_reader.rb +30 -9
- metadata +19 -9
- data/.travis.yml +0 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 32a9e99d8df26222f374b78f140572a02827e8c8c40e8a11f4c40a6e6ded3979
|
|
4
|
+
data.tar.gz: fdf5f267c8326b6e83e78f08e844d5abeab4df416001a66524d450a6b1788c32
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 6d554fceb67114a3778a42da6b68b2a5645b18fca4fe84832c63cce114af0382cf6ebe9c9bf9ff2c703724689d91ca8f87a64450cd8e252c7424e86a2cac0200
|
|
7
|
+
data.tar.gz: 41ff59ddd6640475651d002743c412ffceb0f4401a0015a5b249003468cc25820a5f1d4db94745a7e6a85b51d1f3ab87e38556fa6e451cf22cc073be063e682b
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [master]
|
|
6
|
+
pull_request:
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
test:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
strategy:
|
|
12
|
+
fail-fast: false
|
|
13
|
+
matrix:
|
|
14
|
+
ruby: ['3.1', '3.2', '3.3', '3.4']
|
|
15
|
+
steps:
|
|
16
|
+
- uses: actions/checkout@v4
|
|
17
|
+
- uses: ruby/setup-ruby@v1
|
|
18
|
+
with:
|
|
19
|
+
ruby-version: ${{ matrix.ruby }}
|
|
20
|
+
bundler-cache: true
|
|
21
|
+
- run: bundle exec rspec
|
data/.gitignore
CHANGED
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
language_colors (0.1.
|
|
4
|
+
language_colors (0.1.4)
|
|
5
|
+
json (~> 2.0)
|
|
5
6
|
|
|
6
7
|
GEM
|
|
7
8
|
remote: https://rubygems.org/
|
|
8
9
|
specs:
|
|
9
10
|
diff-lcs (1.5.1)
|
|
10
|
-
json (2.
|
|
11
|
-
rake (
|
|
11
|
+
json (2.21.1)
|
|
12
|
+
rake (13.4.2)
|
|
12
13
|
rspec (3.13.0)
|
|
13
14
|
rspec-core (~> 3.13.0)
|
|
14
15
|
rspec-expectations (~> 3.13.0)
|
|
@@ -27,10 +28,9 @@ PLATFORMS
|
|
|
27
28
|
ruby
|
|
28
29
|
|
|
29
30
|
DEPENDENCIES
|
|
30
|
-
json
|
|
31
31
|
language_colors!
|
|
32
|
-
rake (~>
|
|
32
|
+
rake (~> 13.0)
|
|
33
33
|
rspec (~> 3.0)
|
|
34
34
|
|
|
35
35
|
BUNDLED WITH
|
|
36
|
-
2.
|
|
36
|
+
2.5.21
|
data/README.md
CHANGED
|
@@ -29,6 +29,13 @@ lc.color('C++')
|
|
|
29
29
|
```
|
|
30
30
|
|
|
31
31
|
|
|
32
|
+
## Updating the color list
|
|
33
|
+
|
|
34
|
+
The colors are generated from [GitHub Linguist](https://github.com/github/linguist)'s
|
|
35
|
+
`languages.yml`. To refresh `lib/colors.json` with the latest data:
|
|
36
|
+
|
|
37
|
+
$ rake colors
|
|
38
|
+
|
|
32
39
|
## Contributing
|
|
33
40
|
|
|
34
41
|
Bug reports and pull requests are welcome on GitHub at https://github.com/SyedAbuTalib/language_colors. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/SyedAbuTalib/language_colors/blob/master/CODE_OF_CONDUCT.md).
|
data/Rakefile
CHANGED
data/language_colors.gemspec
CHANGED
data/lib/colors.json
CHANGED
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
"AGS Script": "#B9D9FF",
|
|
8
8
|
"AIDL": "#34EB6B",
|
|
9
9
|
"AL": "#3AA2B5",
|
|
10
|
+
"ALGOL": "#D1E0DB",
|
|
10
11
|
"AMPL": "#E6EFBB",
|
|
11
12
|
"ANTLR": "#9DC3FF",
|
|
12
13
|
"API Blueprint": "#2ACCA8",
|
|
@@ -18,10 +19,12 @@
|
|
|
18
19
|
"Adblock Filter List": "#800000",
|
|
19
20
|
"Adobe Font Metrics": "#fa0f00",
|
|
20
21
|
"Agda": "#315665",
|
|
22
|
+
"Aiken": "#640ff8",
|
|
21
23
|
"Alloy": "#64C800",
|
|
22
24
|
"Alpine Abuild": "#0D597F",
|
|
23
25
|
"Altium Designer": "#A89663",
|
|
24
26
|
"AngelScript": "#C7D7DC",
|
|
27
|
+
"Answer Set Programming": "#A9CC29",
|
|
25
28
|
"Ant Build System": "#A9157E",
|
|
26
29
|
"Antlers": "#ff269e",
|
|
27
30
|
"ApacheConf": "#d12127",
|
|
@@ -39,7 +42,11 @@
|
|
|
39
42
|
"AutoIt": "#1C3552",
|
|
40
43
|
"Avro IDL": "#0040FF",
|
|
41
44
|
"Awk": "#c30e9b",
|
|
45
|
+
"B (Formal Method)": "#8aa8c5",
|
|
46
|
+
"B4X": "#00e4ff",
|
|
47
|
+
"BAML": "#a855f7",
|
|
42
48
|
"BASIC": "#ff0000",
|
|
49
|
+
"BQN": "#2b7067",
|
|
43
50
|
"Ballerina": "#FF5000",
|
|
44
51
|
"Batchfile": "#C1F12E",
|
|
45
52
|
"Beef": "#a52f4e",
|
|
@@ -52,6 +59,7 @@
|
|
|
52
59
|
"Blade": "#f7523f",
|
|
53
60
|
"BlitzBasic": "#00FFAE",
|
|
54
61
|
"BlitzMax": "#cd6400",
|
|
62
|
+
"Blueprint": "#3584E4",
|
|
55
63
|
"Bluespec": "#12223c",
|
|
56
64
|
"Bluespec BH": "#12223c",
|
|
57
65
|
"Boo": "#d4bec1",
|
|
@@ -60,23 +68,31 @@
|
|
|
60
68
|
"BrighterScript": "#66AABB",
|
|
61
69
|
"Brightscript": "#662D91",
|
|
62
70
|
"Browserslist": "#ffd539",
|
|
71
|
+
"Bru": "#F4AA41",
|
|
72
|
+
"BuildStream": "#006bff",
|
|
63
73
|
"C": "#555555",
|
|
64
|
-
"C#": "#
|
|
74
|
+
"C#": "#7355dd",
|
|
65
75
|
"C++": "#f34b7d",
|
|
76
|
+
"C3": "#2563eb",
|
|
66
77
|
"CAP CDS": "#0092d1",
|
|
67
78
|
"CLIPS": "#00A300",
|
|
68
79
|
"CMake": "#DA3434",
|
|
69
80
|
"COLLADA": "#F1A42B",
|
|
81
|
+
"CQL": "#006091",
|
|
70
82
|
"CSON": "#244776",
|
|
71
|
-
"CSS": "#
|
|
83
|
+
"CSS": "#663399",
|
|
72
84
|
"CSV": "#237346",
|
|
73
85
|
"CUE": "#5886E1",
|
|
74
86
|
"CWeb": "#00007a",
|
|
75
87
|
"Cabal Config": "#483465",
|
|
88
|
+
"Caddyfile": "#22b638",
|
|
76
89
|
"Cadence": "#00ef8b",
|
|
77
90
|
"Cairo": "#ff4a48",
|
|
91
|
+
"Cairo Zero": "#ff4a48",
|
|
78
92
|
"CameLIGO": "#3be133",
|
|
93
|
+
"Cangjie": "#00868B",
|
|
79
94
|
"Cap'n Proto": "#c42727",
|
|
95
|
+
"Carbon": "#222222",
|
|
80
96
|
"Ceylon": "#dfa535",
|
|
81
97
|
"Chapel": "#8dc63f",
|
|
82
98
|
"ChucK": "#3f8000",
|
|
@@ -90,6 +106,7 @@
|
|
|
90
106
|
"Clojure": "#db5855",
|
|
91
107
|
"Closure Templates": "#0d948f",
|
|
92
108
|
"Cloud Firestore Security Rules": "#FFA000",
|
|
109
|
+
"Clue": "#0009b5",
|
|
93
110
|
"CodeQL": "#140f46",
|
|
94
111
|
"CoffeeScript": "#244776",
|
|
95
112
|
"ColdFusion": "#ed2cd6",
|
|
@@ -97,13 +114,14 @@
|
|
|
97
114
|
"Common Lisp": "#3fb68b",
|
|
98
115
|
"Common Workflow Language": "#B5314C",
|
|
99
116
|
"Component Pascal": "#B0CE4E",
|
|
100
|
-
"
|
|
117
|
+
"Cooklang": "#E15A29",
|
|
101
118
|
"Crystal": "#000100",
|
|
102
119
|
"Csound": "#1a1a1a",
|
|
103
120
|
"Csound Document": "#1a1a1a",
|
|
104
121
|
"Csound Score": "#1a1a1a",
|
|
105
122
|
"Cuda": "#3A4E3A",
|
|
106
123
|
"Curry": "#531242",
|
|
124
|
+
"Cylc": "#00b3fd",
|
|
107
125
|
"Cypher": "#34c0eb",
|
|
108
126
|
"Cython": "#fedf5b",
|
|
109
127
|
"D": "#ba595e",
|
|
@@ -112,6 +130,7 @@
|
|
|
112
130
|
"Dafny": "#FFEC25",
|
|
113
131
|
"Darcs Patch": "#8eff23",
|
|
114
132
|
"Dart": "#00B4AB",
|
|
133
|
+
"Daslang": "#d3d3d3",
|
|
115
134
|
"DataWeave": "#003a52",
|
|
116
135
|
"Debian Package Control File": "#D70751",
|
|
117
136
|
"DenizenScript": "#FBEE96",
|
|
@@ -120,6 +139,7 @@
|
|
|
120
139
|
"Dockerfile": "#384d54",
|
|
121
140
|
"Dogescript": "#cca760",
|
|
122
141
|
"Dotenv": "#e5d559",
|
|
142
|
+
"Dune": "#89421e",
|
|
123
143
|
"Dylan": "#6c616e",
|
|
124
144
|
"E": "#ccce35",
|
|
125
145
|
"ECL": "#8a1267",
|
|
@@ -145,6 +165,7 @@
|
|
|
145
165
|
"F#": "#b845fc",
|
|
146
166
|
"F*": "#572e30",
|
|
147
167
|
"FIGlet Font": "#FFDDBB",
|
|
168
|
+
"FIRRTL": "#2f632f",
|
|
148
169
|
"FLUX": "#88ccff",
|
|
149
170
|
"Factor": "#636746",
|
|
150
171
|
"Fancy": "#7b9db4",
|
|
@@ -152,11 +173,13 @@
|
|
|
152
173
|
"Faust": "#c37240",
|
|
153
174
|
"Fennel": "#fff3d7",
|
|
154
175
|
"Filebench WML": "#F6B900",
|
|
176
|
+
"FlatBuffers": "#ed284a",
|
|
177
|
+
"Flix": "#d44a45",
|
|
155
178
|
"Fluent": "#ffcc33",
|
|
156
179
|
"Forth": "#341708",
|
|
157
180
|
"Fortran": "#4d41b1",
|
|
158
181
|
"Fortran Free Form": "#4d41b1",
|
|
159
|
-
"
|
|
182
|
+
"FreeBASIC": "#141AC9",
|
|
160
183
|
"FreeMarker": "#0050b2",
|
|
161
184
|
"Frege": "#00cafe",
|
|
162
185
|
"Futhark": "#5f021f",
|
|
@@ -166,6 +189,7 @@
|
|
|
166
189
|
"GAP": "#0000cc",
|
|
167
190
|
"GCC Machine Description": "#FFCFAB",
|
|
168
191
|
"GDScript": "#355570",
|
|
192
|
+
"GDShader": "#478CBF",
|
|
169
193
|
"GEDCOM": "#003058",
|
|
170
194
|
"GLSL": "#5686a5",
|
|
171
195
|
"GSC": "#FF6800",
|
|
@@ -181,6 +205,7 @@
|
|
|
181
205
|
"Gerber Image": "#d20b00",
|
|
182
206
|
"Gherkin": "#5B2063",
|
|
183
207
|
"Git Attributes": "#F44D27",
|
|
208
|
+
"Git Commit": "#F44D27",
|
|
184
209
|
"Git Config": "#F44D27",
|
|
185
210
|
"Git Revision List": "#F44D27",
|
|
186
211
|
"Gleam": "#ffaff3",
|
|
@@ -191,6 +216,7 @@
|
|
|
191
216
|
"Go": "#00ADD8",
|
|
192
217
|
"Go Checksums": "#00ADD8",
|
|
193
218
|
"Go Module": "#00ADD8",
|
|
219
|
+
"Go Template": "#00ADD8",
|
|
194
220
|
"Go Workspace": "#00ADD8",
|
|
195
221
|
"Godot Resource": "#355570",
|
|
196
222
|
"Golo": "#88562A",
|
|
@@ -203,8 +229,10 @@
|
|
|
203
229
|
"Graphviz (DOT)": "#2596be",
|
|
204
230
|
"Groovy": "#4298b8",
|
|
205
231
|
"Groovy Server Pages": "#4298b8",
|
|
232
|
+
"GtkRC": "#7fe719",
|
|
206
233
|
"HAProxy": "#106da9",
|
|
207
234
|
"HCL": "#844FBA",
|
|
235
|
+
"HIP": "#4F3A4F",
|
|
208
236
|
"HLSL": "#aace60",
|
|
209
237
|
"HOCON": "#9ff8ee",
|
|
210
238
|
"HTML": "#e34c26",
|
|
@@ -219,15 +247,19 @@
|
|
|
219
247
|
"Haml": "#ece2a9",
|
|
220
248
|
"Handlebars": "#f7931e",
|
|
221
249
|
"Harbour": "#0e60e3",
|
|
250
|
+
"Hare": "#9d7424",
|
|
222
251
|
"Haskell": "#5e5086",
|
|
223
252
|
"Haxe": "#df7900",
|
|
224
253
|
"HiveQL": "#dce200",
|
|
225
254
|
"HolyC": "#ffefaf",
|
|
226
255
|
"Hosts File": "#308888",
|
|
256
|
+
"Hurl": "#FF0288",
|
|
227
257
|
"Hy": "#7790B2",
|
|
228
258
|
"IDL": "#a3522f",
|
|
229
259
|
"IGOR Pro": "#0000cc",
|
|
260
|
+
"IL Assembly": "#512BD4",
|
|
230
261
|
"INI": "#d1dbe0",
|
|
262
|
+
"ISPC": "#2D68B1",
|
|
231
263
|
"Idris": "#b30000",
|
|
232
264
|
"Ignore List": "#000000",
|
|
233
265
|
"ImageJ Macro": "#99AAFF",
|
|
@@ -246,11 +278,14 @@
|
|
|
246
278
|
"JSON5": "#267CB9",
|
|
247
279
|
"JSONLD": "#0c479c",
|
|
248
280
|
"JSONiq": "#40d47e",
|
|
281
|
+
"Jac": "#FC792D",
|
|
282
|
+
"Jai": "#ab8b4b",
|
|
249
283
|
"Janet": "#0886a5",
|
|
250
284
|
"Jasmin": "#d03600",
|
|
251
285
|
"Java": "#b07219",
|
|
252
286
|
"Java Properties": "#2A6277",
|
|
253
287
|
"Java Server Pages": "#2A6277",
|
|
288
|
+
"Java Template Engine": "#2A6277",
|
|
254
289
|
"JavaScript": "#f1e05a",
|
|
255
290
|
"JavaScript+ERB": "#f1e05a",
|
|
256
291
|
"Jest Snapshot": "#15c213",
|
|
@@ -261,8 +296,12 @@
|
|
|
261
296
|
"Jolie": "#843179",
|
|
262
297
|
"Jsonnet": "#0064bd",
|
|
263
298
|
"Julia": "#a270ba",
|
|
299
|
+
"Julia REPL": "#a270ba",
|
|
264
300
|
"Jupyter Notebook": "#DA5B0B",
|
|
265
301
|
"Just": "#384d54",
|
|
302
|
+
"KCL": "#7ABABF",
|
|
303
|
+
"KDL": "#ffb3b3",
|
|
304
|
+
"KFramework": "#4195c5",
|
|
266
305
|
"KRL": "#28430A",
|
|
267
306
|
"Kaitai Struct": "#773b37",
|
|
268
307
|
"KakouneScript": "#6f8042",
|
|
@@ -270,27 +309,36 @@
|
|
|
270
309
|
"KiCad Layout": "#2f4aab",
|
|
271
310
|
"KiCad Legacy Layout": "#2f4aab",
|
|
272
311
|
"KiCad Schematic": "#2f4aab",
|
|
312
|
+
"KoLmafia ASH": "#B9D9B9",
|
|
313
|
+
"Koka": "#215166",
|
|
273
314
|
"Kotlin": "#A97BFF",
|
|
274
315
|
"LFE": "#4C3023",
|
|
275
316
|
"LLVM": "#185619",
|
|
276
317
|
"LOLCODE": "#cc9900",
|
|
277
318
|
"LSL": "#3d9970",
|
|
278
319
|
"LabVIEW": "#fede06",
|
|
320
|
+
"Lambdapi": "#8027a3",
|
|
321
|
+
"Langium": "#2c8c87",
|
|
279
322
|
"Lark": "#2980B9",
|
|
280
323
|
"Lasso": "#999999",
|
|
281
324
|
"Latte": "#f2a542",
|
|
325
|
+
"Leo": "#C4FFC2",
|
|
282
326
|
"Less": "#1d365d",
|
|
283
327
|
"Lex": "#DBCA00",
|
|
284
328
|
"LigoLANG": "#0e74ff",
|
|
285
329
|
"LilyPond": "#9ccc7c",
|
|
286
330
|
"Liquid": "#67b8de",
|
|
331
|
+
"Liquidsoap": "#990066",
|
|
287
332
|
"Literate Agda": "#315665",
|
|
288
333
|
"Literate CoffeeScript": "#244776",
|
|
289
334
|
"Literate Haskell": "#5e5086",
|
|
335
|
+
"LiveCode Script": "#0c5ba5",
|
|
290
336
|
"LiveScript": "#499886",
|
|
291
337
|
"Logtalk": "#295b9a",
|
|
292
338
|
"LookML": "#652B81",
|
|
293
339
|
"Lua": "#000080",
|
|
340
|
+
"Luau": "#00A2FF",
|
|
341
|
+
"M3U": "#179C7D",
|
|
294
342
|
"MATLAB": "#e16737",
|
|
295
343
|
"MAXScript": "#00a6a6",
|
|
296
344
|
"MDX": "#fcb32c",
|
|
@@ -304,13 +352,15 @@
|
|
|
304
352
|
"Markdown": "#083fa1",
|
|
305
353
|
"Marko": "#42bff2",
|
|
306
354
|
"Mask": "#f97732",
|
|
307
|
-
"
|
|
355
|
+
"Mathematical Programming System": "#0530ad",
|
|
308
356
|
"Max": "#c4a79c",
|
|
357
|
+
"MeTTa": "#6a5acd",
|
|
309
358
|
"Mercury": "#ff2b2b",
|
|
310
359
|
"Mermaid": "#ff3670",
|
|
311
360
|
"Meson": "#007800",
|
|
312
361
|
"Metal": "#8f14e9",
|
|
313
362
|
"MiniYAML": "#ff1111",
|
|
363
|
+
"MiniZinc": "#06a9e6",
|
|
314
364
|
"Mint": "#02b046",
|
|
315
365
|
"Mirah": "#c7a938",
|
|
316
366
|
"Modelica": "#de1d31",
|
|
@@ -318,12 +368,14 @@
|
|
|
318
368
|
"Modula-3": "#223388",
|
|
319
369
|
"Mojo": "#ff4c1f",
|
|
320
370
|
"Monkey C": "#8D6747",
|
|
371
|
+
"MoonBit": "#b92381",
|
|
321
372
|
"MoonScript": "#ff4585",
|
|
322
373
|
"Motoko": "#fbb03b",
|
|
323
374
|
"Motorola 68K Assembly": "#005daa",
|
|
324
375
|
"Move": "#4a137a",
|
|
325
376
|
"Mustache": "#724b3b",
|
|
326
377
|
"NCL": "#28431f",
|
|
378
|
+
"NMODL": "#00356B",
|
|
327
379
|
"NPM Config": "#cb3837",
|
|
328
380
|
"NWScript": "#111522",
|
|
329
381
|
"Nasal": "#1d2c4e",
|
|
@@ -335,9 +387,11 @@
|
|
|
335
387
|
"NewLisp": "#87AED7",
|
|
336
388
|
"Nextflow": "#3ac486",
|
|
337
389
|
"Nginx": "#009639",
|
|
390
|
+
"Nickel": "#E0C3FC",
|
|
338
391
|
"Nim": "#ffc200",
|
|
339
392
|
"Nit": "#009917",
|
|
340
393
|
"Nix": "#7e7eff",
|
|
394
|
+
"Noir": "#2f1f49",
|
|
341
395
|
"Nu": "#c9df40",
|
|
342
396
|
"NumPy": "#9C8AF9",
|
|
343
397
|
"Nunjucks": "#3d8137",
|
|
@@ -347,6 +401,8 @@
|
|
|
347
401
|
"OASv3-json": "#85ea2d",
|
|
348
402
|
"OASv3-yaml": "#85ea2d",
|
|
349
403
|
"OCaml": "#ef7a08",
|
|
404
|
+
"OMNeT++ MSG": "#a0e0a0",
|
|
405
|
+
"OMNeT++ NED": "#08607c",
|
|
350
406
|
"ObjectScript": "#424893",
|
|
351
407
|
"Objective-C": "#438eff",
|
|
352
408
|
"Objective-C++": "#6866fb",
|
|
@@ -363,6 +419,8 @@
|
|
|
363
419
|
"OpenSCAD": "#e5cd45",
|
|
364
420
|
"Option List": "#476732",
|
|
365
421
|
"Org": "#77aa99",
|
|
422
|
+
"OverPy": "#78b355",
|
|
423
|
+
"OverpassQL": "#cce2aa",
|
|
366
424
|
"Oxygene": "#cdd0e3",
|
|
367
425
|
"Oz": "#fab738",
|
|
368
426
|
"P4": "#7055b5",
|
|
@@ -384,16 +442,19 @@
|
|
|
384
442
|
"PigLatin": "#fcd7de",
|
|
385
443
|
"Pike": "#005390",
|
|
386
444
|
"Pip Requirements": "#FFD343",
|
|
445
|
+
"Pkl": "#6b9543",
|
|
387
446
|
"PlantUML": "#fbbd16",
|
|
388
447
|
"PogoScript": "#d80074",
|
|
389
448
|
"Polar": "#ae81ff",
|
|
390
449
|
"Portugol": "#f8bd00",
|
|
391
450
|
"PostCSS": "#dc3a0c",
|
|
392
451
|
"PostScript": "#da291c",
|
|
452
|
+
"Power Query": "#d38e0d",
|
|
393
453
|
"PowerBuilder": "#8f0f8d",
|
|
394
454
|
"PowerShell": "#012456",
|
|
395
455
|
"Praat": "#c8506d",
|
|
396
456
|
"Prisma": "#0c344b",
|
|
457
|
+
"Pro*C": "#bb8368",
|
|
397
458
|
"Processing": "#0096D8",
|
|
398
459
|
"Procfile": "#3B2F63",
|
|
399
460
|
"Prolog": "#74283c",
|
|
@@ -411,12 +472,18 @@
|
|
|
411
472
|
"QML": "#44a51c",
|
|
412
473
|
"Qt Script": "#00b841",
|
|
413
474
|
"Quake": "#882233",
|
|
475
|
+
"QuakeC": "#975777",
|
|
476
|
+
"QuickBASIC": "#008080",
|
|
477
|
+
"Quint": "#9d6ce5",
|
|
414
478
|
"R": "#198CE7",
|
|
415
479
|
"RAML": "#77d9fb",
|
|
480
|
+
"RAScript": "#2C97FA",
|
|
416
481
|
"RBS": "#701516",
|
|
417
482
|
"RDoc": "#701516",
|
|
418
483
|
"REXX": "#d90e09",
|
|
419
484
|
"RMarkdown": "#198ce7",
|
|
485
|
+
"RON": "#a62c00",
|
|
486
|
+
"ROS Interface": "#22314e",
|
|
420
487
|
"RPGLE": "#2BDE21",
|
|
421
488
|
"RUNOFF": "#665a4e",
|
|
422
489
|
"Racket": "#3c5caa",
|
|
@@ -429,6 +496,7 @@
|
|
|
429
496
|
"Rebol": "#358a5b",
|
|
430
497
|
"Record Jar": "#0673ba",
|
|
431
498
|
"Red": "#f50000",
|
|
499
|
+
"Redscript": "#f44336",
|
|
432
500
|
"Regular Expression": "#009a00",
|
|
433
501
|
"Ren'Py": "#ff7f7f",
|
|
434
502
|
"Rez": "#FFDAB3",
|
|
@@ -436,6 +504,7 @@
|
|
|
436
504
|
"Riot": "#A71E49",
|
|
437
505
|
"RobotFramework": "#00c0b5",
|
|
438
506
|
"Roc": "#7c38f5",
|
|
507
|
+
"Rocq Prover": "#d0b68c",
|
|
439
508
|
"Roff": "#ecdebe",
|
|
440
509
|
"Roff Manpage": "#ecdebe",
|
|
441
510
|
"Rouge": "#cc0088",
|
|
@@ -451,6 +520,7 @@
|
|
|
451
520
|
"SRecode Template": "#348a34",
|
|
452
521
|
"STL": "#373b5e",
|
|
453
522
|
"SVG": "#ff9900",
|
|
523
|
+
"Sail": "#259dd5",
|
|
454
524
|
"SaltStack": "#646464",
|
|
455
525
|
"Sass": "#a53b70",
|
|
456
526
|
"Scala": "#c22d40",
|
|
@@ -465,6 +535,7 @@
|
|
|
465
535
|
"Shen": "#120F14",
|
|
466
536
|
"Simple File Verification": "#C9BFED",
|
|
467
537
|
"Singularity": "#64E6AD",
|
|
538
|
+
"Slang": "#1fbec9",
|
|
468
539
|
"Slash": "#007eff",
|
|
469
540
|
"Slice": "#003fa2",
|
|
470
541
|
"Slim": "#2b2b2b",
|
|
@@ -476,6 +547,7 @@
|
|
|
476
547
|
"Snakemake": "#419179",
|
|
477
548
|
"Solidity": "#AA6746",
|
|
478
549
|
"SourcePawn": "#f69e1d",
|
|
550
|
+
"SpiceDB Schema": "#a5318a",
|
|
479
551
|
"Squirrel": "#800000",
|
|
480
552
|
"Stan": "#b2011d",
|
|
481
553
|
"Standard ML": "#dc566d",
|
|
@@ -486,6 +558,8 @@
|
|
|
486
558
|
"SubRip Text": "#9e0101",
|
|
487
559
|
"SugarSS": "#2fcc9f",
|
|
488
560
|
"SuperCollider": "#46390b",
|
|
561
|
+
"SurrealQL": "#ff00a0",
|
|
562
|
+
"Survex data": "#ffcc99",
|
|
489
563
|
"Svelte": "#ff3e00",
|
|
490
564
|
"Sway": "#00F58C",
|
|
491
565
|
"Sweave": "#198ce7",
|
|
@@ -494,14 +568,17 @@
|
|
|
494
568
|
"TI Program": "#A0AA87",
|
|
495
569
|
"TL-Verilog": "#C40023",
|
|
496
570
|
"TLA": "#4b0079",
|
|
571
|
+
"TMDL": "#f0c913",
|
|
497
572
|
"TOML": "#9c4221",
|
|
498
573
|
"TSQL": "#e38c00",
|
|
499
574
|
"TSV": "#237346",
|
|
500
575
|
"TSX": "#3178c6",
|
|
501
576
|
"TXL": "#0178b8",
|
|
577
|
+
"Tact": "#48b5ff",
|
|
502
578
|
"Talon": "#333333",
|
|
503
579
|
"Tcl": "#e4cc98",
|
|
504
580
|
"TeX": "#3D6117",
|
|
581
|
+
"Teal": "#00B1BC",
|
|
505
582
|
"Terra": "#00004c",
|
|
506
583
|
"Terraform Template": "#7b42bb",
|
|
507
584
|
"TextGrid": "#c8506d",
|
|
@@ -509,14 +586,18 @@
|
|
|
509
586
|
"Textile": "#ffe7ac",
|
|
510
587
|
"Thrift": "#D12127",
|
|
511
588
|
"Toit": "#c2c9fb",
|
|
589
|
+
"Tor Config": "#59316b",
|
|
590
|
+
"Tree-sitter Query": "#8ea64c",
|
|
512
591
|
"Turing": "#cf142b",
|
|
513
592
|
"Twig": "#c1d026",
|
|
514
593
|
"TypeScript": "#3178c6",
|
|
594
|
+
"TypeSpec": "#4A3665",
|
|
515
595
|
"Typst": "#239dad",
|
|
516
596
|
"Unified Parallel C": "#4e3617",
|
|
517
597
|
"Unity3D Asset": "#222c37",
|
|
518
598
|
"Uno": "#9933cc",
|
|
519
599
|
"UnrealScript": "#a54c4d",
|
|
600
|
+
"Untyped Plutus Core": "#36adbd",
|
|
520
601
|
"UrWeb": "#ccccee",
|
|
521
602
|
"V": "#4f87c4",
|
|
522
603
|
"VBA": "#867db1",
|
|
@@ -526,6 +607,7 @@
|
|
|
526
607
|
"Vala": "#a56de2",
|
|
527
608
|
"Valve Data Format": "#f26025",
|
|
528
609
|
"Velocity Template Language": "#507cff",
|
|
610
|
+
"Vento": "#ff0080",
|
|
529
611
|
"Verilog": "#b2b7f8",
|
|
530
612
|
"Vim Help File": "#199f4b",
|
|
531
613
|
"Vim Script": "#199f4b",
|
|
@@ -534,7 +616,7 @@
|
|
|
534
616
|
"Visual Basic 6.0": "#2c6353",
|
|
535
617
|
"Volt": "#1F1F1F",
|
|
536
618
|
"Vue": "#41b883",
|
|
537
|
-
"Vyper": "#
|
|
619
|
+
"Vyper": "#9F4CF2",
|
|
538
620
|
"WDL": "#42f1f4",
|
|
539
621
|
"WGSL": "#1a5e9a",
|
|
540
622
|
"Web Ontology Language": "#5b70bd",
|
|
@@ -544,6 +626,7 @@
|
|
|
544
626
|
"Wikitext": "#fc5757",
|
|
545
627
|
"Windows Registry Entries": "#52d5ff",
|
|
546
628
|
"Witcher Script": "#ff0000",
|
|
629
|
+
"Wolfram Language": "#dd1100",
|
|
547
630
|
"Wollok": "#a23738",
|
|
548
631
|
"World of Warcraft Addon Data": "#f7e43f",
|
|
549
632
|
"Wren": "#383838",
|
|
@@ -553,6 +636,7 @@
|
|
|
553
636
|
"XML Property List": "#0060ac",
|
|
554
637
|
"XQuery": "#5232e7",
|
|
555
638
|
"XSLT": "#EB8CEB",
|
|
639
|
+
"Xmake": "#22a079",
|
|
556
640
|
"Xojo": "#81bd41",
|
|
557
641
|
"Xonsh": "#285EEF",
|
|
558
642
|
"Xtend": "#24255d",
|
|
@@ -567,20 +651,27 @@
|
|
|
567
651
|
"Zephir": "#118f9e",
|
|
568
652
|
"Zig": "#ec915c",
|
|
569
653
|
"Zimpl": "#d67711",
|
|
654
|
+
"Zmodel": "#ff7100",
|
|
655
|
+
"crontab": "#ead7ac",
|
|
570
656
|
"eC": "#913960",
|
|
571
657
|
"fish": "#4aae47",
|
|
572
658
|
"hoon": "#00b171",
|
|
659
|
+
"iCalendar": "#ec564c",
|
|
573
660
|
"jq": "#c7254e",
|
|
574
661
|
"kvlang": "#1da6e0",
|
|
575
662
|
"mIRC Script": "#3d57c3",
|
|
576
663
|
"mcfunction": "#E22837",
|
|
664
|
+
"mdsvex": "#5f9ea0",
|
|
577
665
|
"mupad": "#244963",
|
|
578
666
|
"nanorc": "#2d004d",
|
|
579
667
|
"nesC": "#94B0C7",
|
|
580
668
|
"ooc": "#b0b77e",
|
|
669
|
+
"pkg-config": "#2b5e82",
|
|
581
670
|
"q": "#0040cd",
|
|
582
671
|
"reStructuredText": "#141414",
|
|
583
672
|
"sed": "#64b970",
|
|
673
|
+
"templ": "#66D0DD",
|
|
674
|
+
"vCard": "#ee2647",
|
|
584
675
|
"wisp": "#7582D1",
|
|
585
676
|
"xBase": "#403a40"
|
|
586
677
|
}
|
data/lib/language_colors.rb
CHANGED
|
@@ -6,18 +6,17 @@ require 'json'
|
|
|
6
6
|
# Module to hold the class
|
|
7
7
|
module LanguageColors
|
|
8
8
|
class Error < StandardError; end
|
|
9
|
-
# Your code goes here...
|
|
10
|
-
@hash = Hash.new(false)
|
|
11
9
|
|
|
12
|
-
#
|
|
10
|
+
# Looks up the GitHub/Linguist color for a language name.
|
|
13
11
|
class LanguageColors
|
|
12
|
+
COLORS_FILE = File.join(__dir__, 'colors.json')
|
|
13
|
+
|
|
14
14
|
def initialize
|
|
15
|
-
|
|
16
|
-
File.open(file) do |f|
|
|
17
|
-
@hash = JSON.parse(f.read)
|
|
18
|
-
end
|
|
15
|
+
@hash = JSON.parse(File.read(COLORS_FILE))
|
|
19
16
|
end
|
|
20
17
|
|
|
18
|
+
# Returns the hex color string (e.g. "#f34b7d") for +lang+,
|
|
19
|
+
# or nil if the language is unknown.
|
|
21
20
|
def color(lang)
|
|
22
21
|
@hash[lang]
|
|
23
22
|
end
|
data/lib/linguist_reader.rb
CHANGED
|
@@ -4,15 +4,36 @@ require 'open-uri'
|
|
|
4
4
|
require 'yaml'
|
|
5
5
|
require 'json'
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
# Regenerates lib/colors.json from GitHub Linguist's languages.yml.
|
|
8
|
+
# Run with: ruby lib/linguist_reader.rb (or `rake colors`)
|
|
9
|
+
module LinguistReader
|
|
10
|
+
SOURCE_URL = 'https://raw.githubusercontent.com/github/linguist/master/lib/linguist/languages.yml'
|
|
11
|
+
OUTPUT_FILE = File.join(__dir__, 'colors.json')
|
|
10
12
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
module_function
|
|
14
|
+
|
|
15
|
+
def fetch
|
|
16
|
+
URI.parse(SOURCE_URL).open(&:read)
|
|
17
|
+
rescue OpenURI::HTTPError, SocketError => e
|
|
18
|
+
abort "Failed to download Linguist languages.yml: #{e.message}"
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def build(yaml_content)
|
|
22
|
+
YAML.safe_load(yaml_content).each_with_object({}) do |(name, props), colors|
|
|
23
|
+
color = props['color']
|
|
24
|
+
colors[name] = color unless color.nil?
|
|
25
|
+
end.sort.to_h
|
|
26
|
+
end
|
|
15
27
|
|
|
16
|
-
|
|
17
|
-
|
|
28
|
+
def write(colors)
|
|
29
|
+
File.write(OUTPUT_FILE, "#{JSON.pretty_generate(colors)}\n")
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
def run
|
|
33
|
+
colors = build(fetch)
|
|
34
|
+
write(colors)
|
|
35
|
+
puts "Wrote #{colors.size} language colors to #{OUTPUT_FILE}"
|
|
36
|
+
end
|
|
18
37
|
end
|
|
38
|
+
|
|
39
|
+
LinguistReader.run if $PROGRAM_NAME == __FILE__
|
metadata
CHANGED
|
@@ -1,25 +1,37 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: language_colors
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Syed AbuTalib
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: exe
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
12
|
-
dependencies:
|
|
13
|
-
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
11
|
+
dependencies:
|
|
12
|
+
- !ruby/object:Gem::Dependency
|
|
13
|
+
name: json
|
|
14
|
+
requirement: !ruby/object:Gem::Requirement
|
|
15
|
+
requirements:
|
|
16
|
+
- - "~>"
|
|
17
|
+
- !ruby/object:Gem::Version
|
|
18
|
+
version: '2.0'
|
|
19
|
+
type: :runtime
|
|
20
|
+
prerelease: false
|
|
21
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
22
|
+
requirements:
|
|
23
|
+
- - "~>"
|
|
24
|
+
- !ruby/object:Gem::Version
|
|
25
|
+
version: '2.0'
|
|
14
26
|
email:
|
|
15
27
|
- syedabutalib@github.com
|
|
16
28
|
executables: []
|
|
17
29
|
extensions: []
|
|
18
30
|
extra_rdoc_files: []
|
|
19
31
|
files:
|
|
32
|
+
- ".github/workflows/ci.yml"
|
|
20
33
|
- ".gitignore"
|
|
21
34
|
- ".rspec"
|
|
22
|
-
- ".travis.yml"
|
|
23
35
|
- CODE_OF_CONDUCT.md
|
|
24
36
|
- Gemfile
|
|
25
37
|
- Gemfile.lock
|
|
@@ -40,7 +52,6 @@ metadata:
|
|
|
40
52
|
homepage_uri: https://github.com/SyedAbutalib/language_colors
|
|
41
53
|
source_code_uri: https://github.com/SyedAbutalib/language_colors
|
|
42
54
|
changelog_uri: https://github.com/SyedAbutalib/language_colors
|
|
43
|
-
post_install_message:
|
|
44
55
|
rdoc_options: []
|
|
45
56
|
require_paths:
|
|
46
57
|
- lib
|
|
@@ -55,8 +66,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
55
66
|
- !ruby/object:Gem::Version
|
|
56
67
|
version: '0'
|
|
57
68
|
requirements: []
|
|
58
|
-
rubygems_version:
|
|
59
|
-
signing_key:
|
|
69
|
+
rubygems_version: 4.0.16
|
|
60
70
|
specification_version: 4
|
|
61
71
|
summary: Get a language's color on github.
|
|
62
72
|
test_files: []
|