Skip to content

Commit eddadb8

Browse files
authored
LFS the Lunr Indexes (github#20521)
* LFS the Lunr Indexes * Add a note about installing Git LFS * Run "install" command * Update indexes * Index names
1 parent 6144b2a commit eddadb8

File tree

87 files changed

+125
-54
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

87 files changed

+125
-54
lines changed

.gitattributes

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Set default behaviour, in case users don't have core.autocrlf set.
22
* text=auto
3-
43
# Explicitly declare text files we want to always be normalized and converted
54
# to native line endings on checkout.
65
*.md text
6+
*.json.br filter=lfs diff=lfs merge=lfs -text

.husky/post-checkout

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/post-checkout.\n"; exit 2; }
3+
git lfs post-checkout "$@"

.husky/post-commit

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/post-commit.\n"; exit 2; }
3+
git lfs post-commit "$@"

.husky/post-merge

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/post-merge.\n"; exit 2; }
3+
git lfs post-merge "$@"

.husky/pre-push

+3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
#!/bin/sh
2+
command -v git-lfs >/dev/null 2>&1 || { echo >&2 "\nThis repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/pre-push.\n"; exit 2; }
3+
git lfs pre-push "$@"
4+
25
. "$(dirname "$0")/_/husky.sh"
36

47
npm run prevent-pushes-to-main

CONTRIBUTING.md

+2

contributing/development.md

+3-1

lib/search/cached-index-names.json

-51
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,7 @@
11
[
2-
"github-docs-2.17-cn",
3-
"github-docs-2.17-de",
4-
"github-docs-2.17-en",
5-
"github-docs-2.17-es",
6-
"github-docs-2.17-ja",
7-
"github-docs-2.17-pt",
8-
"github-docs-2.18-cn",
9-
"github-docs-2.18-de",
10-
"github-docs-2.18-en",
11-
"github-docs-2.18-es",
12-
"github-docs-2.18-ja",
13-
"github-docs-2.18-pt",
14-
"github-docs-2.19-cn",
15-
"github-docs-2.19-de",
16-
"github-docs-2.19-en",
17-
"github-docs-2.19-es",
18-
"github-docs-2.19-ja",
19-
"github-docs-2.19-pt",
202
"github-docs-2.20-cn",
21-
"github-docs-2.20-de",
223
"github-docs-2.20-en",
23-
"github-docs-2.20-es",
244
"github-docs-2.20-ja",
25-
"github-docs-2.20-pt",
265
"github-docs-2.21-cn",
276
"github-docs-2.21-de",
287
"github-docs-2.21-en",
@@ -47,36 +26,6 @@
4726
"github-docs-3.1-es",
4827
"github-docs-3.1-ja",
4928
"github-docs-3.1-pt",
50-
"github-docs-custom-rankings-2.18-cn",
51-
"github-docs-custom-rankings-2.18-de",
52-
"github-docs-custom-rankings-2.18-en",
53-
"github-docs-custom-rankings-2.18-es",
54-
"github-docs-custom-rankings-2.18-ja",
55-
"github-docs-custom-rankings-2.18-pt",
56-
"github-docs-custom-rankings-2.19-cn",
57-
"github-docs-custom-rankings-2.19-de",
58-
"github-docs-custom-rankings-2.19-en",
59-
"github-docs-custom-rankings-2.19-es",
60-
"github-docs-custom-rankings-2.19-ja",
61-
"github-docs-custom-rankings-2.19-pt",
62-
"github-docs-custom-rankings-2.20-cn",
63-
"github-docs-custom-rankings-2.20-de",
64-
"github-docs-custom-rankings-2.20-en",
65-
"github-docs-custom-rankings-2.20-es",
66-
"github-docs-custom-rankings-2.20-ja",
67-
"github-docs-custom-rankings-2.20-pt",
68-
"github-docs-custom-rankings-2.21-cn",
69-
"github-docs-custom-rankings-2.21-de",
70-
"github-docs-custom-rankings-2.21-en",
71-
"github-docs-custom-rankings-2.21-es",
72-
"github-docs-custom-rankings-2.21-ja",
73-
"github-docs-custom-rankings-2.21-pt",
74-
"github-docs-custom-rankings-dotcom-cn",
75-
"github-docs-custom-rankings-dotcom-de",
76-
"github-docs-custom-rankings-dotcom-en",
77-
"github-docs-custom-rankings-dotcom-es",
78-
"github-docs-custom-rankings-dotcom-ja",
79-
"github-docs-custom-rankings-dotcom-pt",
8029
"github-docs-dotcom-cn",
8130
"github-docs-dotcom-de",
8231
"github-docs-dotcom-en",
Binary file not shown.
-1.1 MB
Binary file not shown.
Binary file not shown.
-2.63 MB
Binary file not shown.
Binary file not shown.
-3.42 MB
Binary file not shown.
Binary file not shown.
-1.11 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:73b55743a2940587e669cce04e2e3ed1857de9651b2220be1b66c73249f6da89
3+
size 430858
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:6d46001582f77ca2d27986fd52907c6a765f9e1f2dc5face11b09d3cea8910b6
3+
size 1929073
Binary file not shown.
-2.68 MB
Binary file not shown.
Binary file not shown.
-2.35 MB
Binary file not shown.
Binary file not shown.
-3.46 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:81ed912d45627240be98b392afbfa7ce7d9e01fc251214974d7ece51fff68080
3+
size 410908
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:14cc31ad7051a742275a65f53f0d12ecb1556a77c0e449040ed4218c846b4c58
3+
size 1759084
Binary file not shown.
-1.48 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:7adbf7aec1315045d30d22e5716d9f600f37dfad24188fba0306e9a65259b3e5
3+
size 529258
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:6ef5fb7690c26f83682eb08e9eefa2c57a59556adf651625a6506dd35fd85256
3+
size 2434837
Binary file not shown.
-3.47 MB
Binary file not shown.
Binary file not shown.
-2.63 MB
Binary file not shown.
Binary file not shown.
-4.47 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:9511f09ef860f31da34612a7df48a4fed0cae6e1af59ab7ad2001d75ee08f5f1
3+
size 504140
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:d859df9db5aa053f32f4a622860c59a8bfc954ddaaf3eca71ac0162c33421154
3+
size 2191945
Binary file not shown.
-1.54 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:b0f8aa93c2957341a14f8932118ea0e6211ae58f547b2be3b13b13bc34f8aca4
3+
size 551428
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:4667211ebb1d32a6c6cd04dd722cab752b56eecf22a82e1c3b9428b9b3158632
3+
size 2543659
Binary file not shown.
-3.58 MB
Binary file not shown.
Binary file not shown.
-2.64 MB
Binary file not shown.
Binary file not shown.
-4.61 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:bba9b6174734a3bd4d81dc181862f2ca904ac66d0397d07df5fdb26c7ba474a9
3+
size 526917
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:ae17af5b47275cfe4db5c379c2043e143cd0a3be7e2887007d42558c1a43f0f7
3+
size 2284397
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:ba020ea211f66b318d3e2b14368f0c6707ee7c1df29159ba519f5ed61a386463
3+
size 595686
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:1d1364dd2e5eb70bdcae5ee027dff1d42b3ae882588e9ccaa7ea838c7311f117
3+
size 1109848
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:fbb4fa11028b98f7721a752b41c6a911bc022d7e83c7388011f9a312ca444b8b
3+
size 558953
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:a8288e5414f00e1fb7abba7790ff75af386160b0a573ec0de545f49791c42d0d
3+
size 2594622
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:6233fe8021b895caa05fc54ad30c36f32589f927afba8a8ee1db694f36febeed
3+
size 775856
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:607138c4479bbbd92a45643a0981feda313335107973b373f7ee652430487910
3+
size 3806754
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:0481a44a636adfae94ebc53c10b81d771577baf953df16a7489e13c8c9465c5f
3+
size 339857
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:3666694921a7f96ef9a7db7b90a4d2a68b64f927f19380a8af487380b28f4571
3+
size 1385067
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:6011c94b01d601308a112b4182da6ff92bc7854d8a40fc3543ba027f925a2d8c
3+
size 622311
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:75a2bff493b6d904eb8c5b9c6a5cf008c66440be27ffd426074d75154fceb7db
3+
size 3472368
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:63df71e7bd3c87338d81b6334cd923d1740312bf488ae0035c2df48d20cd0fe0
3+
size 535822
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:8ca8cc1f1115d23b5f27c3d9b27d6f5058f6efb8bf280845e84c19791f59867e
3+
size 2329678
Binary file not shown.
-1.74 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:41721b2405fdb345ba1940cffb4f4854572a9556afe3b3c946a6d6e8f0d3f061
3+
size 714818
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:a2bfc54b08550222eba7af30846a0146ae5c6f74842b33e7e4dede021be7c207
3+
size 3302158
Binary file not shown.
-4.37 MB
Binary file not shown.
Binary file not shown.
-3.16 MB
Binary file not shown.
Binary file not shown.
-5.72 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:4787ac2709036c2304cd4bf4bc115f4a96db2e54f754b819b5849585297b6f2f
3+
size 690413
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:510104746e56d3df7540e1842d18bf2646008612e2bfc5deb7f501106fa0ccdb
3+
size 2942521
Binary file not shown.
-866 KB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:b87621568ee2b8a892474b855e347a675f289da3760b92c87269bd48efdd477f
3+
size 442796
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:863874dd302bead37f8114ee5bb0bc4127b0c11d93c47952a768a34621213bac
3+
size 2010669
Binary file not shown.
-2.06 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:d9bac6f249c1ab5aafe3deb1aa1967886cadd3ba29df92b2631985ab6a1e1e1c
3+
size 252550
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:6369c612b21bbe8a776725b5b6a2d6111f826ada6962c700c5adf1dbd6062ac9
3+
size 1000350
Binary file not shown.
-2.53 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:abf0b3454c1cc9c963ccca7b72bc554fb5ddcf88618a4a533532a3485ee26a41
3+
size 424356
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
version https://git-lfs.github.com/spec/v1
2+
oid sha256:181b3eba0bd68d8e4deaf31e790ecc8173f161b523f3acd383904ed28b3c281f
3+
size 1798360

script/search/lunr-get-index-names.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,9 @@ const __dirname = path.dirname(fileURLToPath(import.meta.url))
66
const fs = xFs.promises
77

88
export default async function getIndexNames() {
9-
return await fs.readdir(path.join(__dirname, '../../lib/search/indexes'))
9+
const indexList = await fs.readdir(path.join(__dirname, '../../lib/search/indexes'))
10+
return indexList
11+
.sort()
12+
.filter((index) => !index.includes('records'))
13+
.map((index) => index.replace('.json.br', ''))
1014
}

0 commit comments

Comments
 (0)