color-name-list 10.17.0 → 10.19.0

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "color-name-list",
3
- "version": "10.17.0",
3
+ "version": "10.19.0",
4
4
  "description": "long list of color names",
5
5
  "main": "dist/colornames.json",
6
6
  "browser": "dist/colornames.umd.js",
@@ -9,8 +9,9 @@
9
9
  "pull-colors": "curl -L 'https://docs.google.com/spreadsheets/d/e/2PACX-1vQube6Y0wHyEtJnjg0eU3N7VseoxVnD4L9uDqvWZdl_tzzrHDVN10IPP7cdFipX8j70atNMLfPCB0Q6/pub?gid=40578722&single=true&output=csv' -o src/colornames.csv",
10
10
  "test": "node scripts/build.js --testOnly",
11
11
  "clean-dist-folder": "rm -rf dist && mkdir dist",
12
- "build": "npm run clean-dist-folder && node scripts/build.js",
13
- "semantic-release": "semantic-release"
12
+ "build": "npm run clean-dist-folder && node scripts/build.js && npm run build-history",
13
+ "semantic-release": "semantic-release",
14
+ "build-history": "node scripts/tools/history.js > dist/history.json"
14
15
  },
15
16
  "repository": {
16
17
  "type": "git",
@@ -0,0 +1,66 @@
1
+ const child_process = require("child_process");
2
+ const readline = require("readline");
3
+
4
+ function cmd(c) {
5
+ const stdout = child_process.execSync(c);
6
+ return stdout.toString().trim();
7
+ }
8
+
9
+ // Print the list of colors added/removed/changed by date.
10
+ // Pretty inefficient due to the many git commands (optimized for clarity)
11
+ async function main() {
12
+
13
+ // Grab the list of all git commits
14
+ const allCommits = cmd("git log --pretty=format:%h").split("\n").filter(Boolean);
15
+
16
+ // The data, one element for each commit (date)
17
+ const dat = [];
18
+
19
+ for (const commit of allCommits) {
20
+
21
+ // Figure out what changed in that particular commit
22
+ const diff = cmd(`git show ${commit} -- ./src/colornames.csv`)
23
+ .split("\n").filter(Boolean);
24
+
25
+ // Grab the date for said commit
26
+ const dt = cmd(`git show -s ${commit} --format=%ci`);
27
+
28
+ // The list of color modified (indexed by hex value) with "op" (+/-/~)
29
+ const modified = {};
30
+
31
+ for(const line of diff) {
32
+ const res = line.match(/^((?<op>(\+|-)))(?<name>[^,]+),(?<hex>[^,]+)/)
33
+ if(!res) { continue; }
34
+ const name = res.groups?.name;
35
+ const hex = res.groups?.hex;
36
+ var op = res.groups?.op;
37
+
38
+ // If a value already introduced with a different op, then it's
39
+ // a modification
40
+ if(modified[hex] && modified[hex].op !== op) { op = "~" }
41
+
42
+ modified[hex] = { hex, name, op };
43
+ }
44
+
45
+ // Partition by added/removed/changed
46
+
47
+ const added = Object.values(modified)
48
+ .filter(x => x.op === "+")
49
+ .map(({name, hex}) => ({ name, hex }));
50
+
51
+ const removed = Object.values(modified)
52
+ .filter(x => x.op === "-")
53
+ .map(({name, hex}) => ({ name, hex }));
54
+
55
+ const changed = Object.values(modified)
56
+ .filter(x => x.op === "~")
57
+ .map(({name, hex}) => ({ name, hex }));
58
+
59
+ // Add the day
60
+ dat.push({ date: dt, added, removed, changed });
61
+ }
62
+
63
+ console.log(JSON.stringify(dat));
64
+ }
65
+
66
+ main()
@@ -12,6 +12,7 @@ name,hex,good name
12
12
  5-Masted Preußen,#9bafad,
13
13
  8 Bit Eggplant,#990066,x
14
14
  90% Cocoa,#3d1c02,
15
+ 99 Years Blue,#000099,
15
16
  A Brand New Day,#ffaabb,
16
17
  A Certain Shade Of Green,#d1edee,
17
18
  A Dime a Dozen,#d3dde4,x
@@ -2648,6 +2649,7 @@ Black Sable,#434b4d,
2648
2649
  Black Safflower,#302833,
2649
2650
  Black Sand,#5b4e4b,
2650
2651
  Black Sapphire,#434555,
2652
+ Black Sea Night,#052462,x
2651
2653
  Black Shadows,#bfafb2,
2652
2654
  Black Sheep,#0f0d0d,x
2653
2655
  Black Slug,#332211,
@@ -3943,6 +3945,7 @@ Buccaneer Blue,#035b8d,
3943
3945
  Büchel Cherry,#aa1111,x
3944
3946
  Buckeye,#674834,x
3945
3947
  Bucking Bronco,#996655,
3948
+ Buckingham Gardens,#89a068,x
3946
3949
  Buckingham Palace,#6b5140,
3947
3950
  Buckram Binding,#d9c3a6,
3948
3951
  Buckskin,#d4ba8c,
@@ -7286,6 +7289,7 @@ Dartmouth Green,#00703c,
7286
7289
  Dash of Curry,#ca6e5f,
7287
7290
  Dash of Oregano,#928459,
7288
7291
  Dashing,#eaebe8,
7292
+ Dasyphyllous Green,#0bdb43,
7289
7293
  Date Fruit Brown,#af642b,
7290
7294
  DaVanzo Beige,#ccac86,
7291
7295
  DaVanzo Green,#58936d,
@@ -8683,6 +8687,7 @@ Elite Teal,#133337,x
8683
8687
  Elite Wisteria,#987fa9,
8684
8688
  Elizabeth Blue,#a1b8d2,
8685
8689
  Elizabeth Rose,#fadfd2,
8690
+ Elk,#a58d72,
8686
8691
  Elk Horn,#e9e2d3,
8687
8692
  Elk Skin,#eae6dc,
8688
8693
  Elkhound,#897269,
@@ -8906,6 +8911,7 @@ Environmental Green,#006c4b,
8906
8911
  Environmental Study,#88bb00,
8907
8912
  Envisage,#96bfb7,
8908
8913
  Envy,#8ba58f,x
8914
+ Envy’s Love,#2dd78d,x
8909
8915
  Eon,#d4d3c9,
8910
8916
  Eosin Pink,#ff5ec4,x
8911
8917
  Ephemera,#7a6270,
@@ -11252,6 +11258,7 @@ Goldie Oldie,#baad75,
11252
11258
  Goldilocks,#fff39a,x
11253
11259
  Goldsmith,#eeb550,
11254
11260
  Goldvreneli 1882,#e7de54,
11261
+ Goldzilla,#cdd80d,x
11255
11262
  Golem,#836e59,x
11256
11263
  Golf Blazer,#53a391,
11257
11264
  Golf Course,#5a9e4b,x
@@ -13234,6 +13241,7 @@ Impressive Ivory,#f4dec3,
13234
13241
  Improbable,#6e7376,
13235
13242
  Impromptu,#705f63,
13236
13243
  Impulse,#005b87,
13244
+ Impulse Blue,#006699,
13237
13245
  Impulsive Purple,#624977,
13238
13246
  Impure White,#f5e7e3,
13239
13247
  Imrik Blue,#67aed0,
@@ -13687,6 +13695,7 @@ Jade Mountain,#34c2a7,
13687
13695
  Jade Mussel Green,#166a45,
13688
13696
  Jade of Emeralds,#318f33,
13689
13697
  Jade Orchid,#00aaaa,
13698
+ Jade Palace,#d0eed7,x
13690
13699
  Jade Powder,#2baf6a,
13691
13700
  Jade Sea,#b8e0d0,x
13692
13701
  Jade Shard,#017b92,
@@ -15949,6 +15958,7 @@ Majestic,#5d4250,
15949
15958
  Majestic Blue,#3f425c,
15950
15959
  Majestic Dune,#f3bc80,x
15951
15960
  Majestic Eggplant,#443388,x
15961
+ Majestic Elk,#ad9a84,x
15952
15962
  Majestic Evergreen,#7d8878,x
15953
15963
  Majestic Jungle,#607535,
15954
15964
  Majestic Magenta,#ee4488,x
@@ -16137,6 +16147,7 @@ Margarine,#f2d930,
16137
16147
  Margarita,#a9bc81,
16138
16148
  Mariana Trench,#445956,
16139
16149
  Marigold,#fcc006,x
16150
+ Marigold Dust,#f5cc3d,
16140
16151
  Marigold Yellow,#fbe870,
16141
16152
  Marilyn Monroe,#e7c3ac,
16142
16153
  Marilyn MonRouge,#c9001e,x
@@ -22887,6 +22898,7 @@ Royal Blood,#105e80,
22887
22898
  Royal Blue,#4169e1,
22888
22899
  Royal Blue Metallic,#082d4f,
22889
22900
  Royal Blue Tang,#1600fc,
22901
+ Royal Blush,#f26e54,x
22890
22902
  Royal Breeze,#275779,
22891
22903
  Royal Brown,#523b35,
22892
22904
  Royal Cloak,#16a5a3,
@@ -22895,6 +22907,7 @@ Royal Coronation,#3e3542,
22895
22907
  Royal Crown,#94714c,
22896
22908
  Royal Curtsy,#282a4a,
22897
22909
  Royal Decree,#403547,x
22910
+ Royal Flush,#a0365f,x
22898
22911
  Royal Flycatcher Crest,#ee6600,
22899
22912
  Royal Fortune,#747792,
22900
22913
  Royal Fuchsia,#ca2c92,
@@ -22980,6 +22993,7 @@ Ruby,#ca0147,x
22980
22993
  Ruby Crystal,#975b60,
22981
22994
  Ruby Dust,#e0115f,
22982
22995
  Ruby Eye,#d0a2a0,
22996
+ Ruby Fire,#f20769,x
22983
22997
  Ruby Grey,#73525c,
22984
22998
  Ruby Lips,#813e45,
22985
22999
  Ruby Queen,#b0063d,x
@@ -1,62 +0,0 @@
1
- name: "CodeQL"
2
-
3
- on:
4
- push:
5
- branches: [master]
6
- pull_request:
7
- # The branches below must be a subset of the branches above
8
- branches: [master]
9
- schedule:
10
- - cron: '0 22 * * 2'
11
-
12
- jobs:
13
- analyze:
14
- name: Analyze
15
- runs-on: ubuntu-latest
16
-
17
- strategy:
18
- fail-fast: false
19
- matrix:
20
- # Override automatic language detection by changing the below list
21
- # Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python']
22
- language: ['javascript']
23
- # Learn more...
24
- # https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection
25
-
26
- steps:
27
- - name: Checkout repository
28
- uses: actions/checkout@v2
29
- with:
30
- # We must fetch at least the immediate parents so that if this is
31
- # a pull request then we can checkout the head.
32
- fetch-depth: 2
33
-
34
- # If this run was triggered by a pull request event, then checkout
35
- # the head of the pull request instead of the merge commit.
36
- - run: git checkout HEAD^2
37
- if: ${{ github.event_name == 'pull_request' }}
38
-
39
- # Initializes the CodeQL tools for scanning.
40
- - name: Initialize CodeQL
41
- uses: github/codeql-action/init@v1
42
- with:
43
- languages: ${{ matrix.language }}
44
-
45
- # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
46
- # If this step fails, then you should remove it and run the build manually (see below)
47
- - name: Autobuild
48
- uses: github/codeql-action/autobuild@v1
49
-
50
- # ℹ️ Command-line programs to run using the OS shell.
51
- # 📚 https://git.io/JvXDl
52
-
53
- # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
54
- # and modify them (or add more) to build your code if your project
55
- # uses a compiled language
56
-
57
- #- run: |
58
- # make bootstrap
59
- # make release
60
-
61
- - name: Perform CodeQL Analysis
62
- uses: github/codeql-action/analyze@v1