Skip to content

Commit 27f979f

Browse files
committed
chore: add Third Party Licenses
1 parent d4b485e commit 27f979f

File tree

8 files changed

+1513
-3
lines changed

8 files changed

+1513
-3
lines changed

.gitattributes

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
11
* text=auto eol=lf
2+
3+
THIRD-PARTY-LICENSES.html linguist-generated
4+
parser/about.hbs linguist-generated

.github/workflows/ci.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,10 @@ jobs:
3434

3535
- run: cd parser && cargo fmt -- --check
3636

37+
- run: |
38+
yarn generate:licenses
39+
git diff --exit-code
40+
3741
- run: yarn build
3842

3943
- run: yarn lint --no-fix

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,3 +82,9 @@ const user = db
8282
.prepare<[], { id: number; name: string }>("SELECT * FROM users")
8383
.all();
8484
```
85+
86+
## License
87+
88+
eslint-plugin-sqlite is licensed under the [MIT License](LICENSE) and
89+
uses various Rust crates compiled to WebAssembly and bundled with the
90+
plugin, their licenses can be found in [Third Party Licenses](THIRD-PARTY-LICENSES.html).

THIRD-PARTY-LICENSES.html

Lines changed: 1404 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
"test": "vitest",
99
"lint": "eslint . --max-warnings 0 --fix",
1010
"format": "prettier --write .",
11-
"prepack": "run build"
11+
"prepack": "run build",
12+
"generate:licenses": "docker build --output ./ ./parser --target license_export && prettier --write THIRD-PARTY-LICENSES.html"
1213
},
1314
"exports": {
1415
".": {
@@ -18,7 +19,8 @@
1819
"./package.json": "./package.json"
1920
},
2021
"files": [
21-
"dist"
22+
"dist",
23+
"THIRD-PARTY-LICENSES.html"
2224
],
2325
"dependencies": {
2426
"@types/better-sqlite3": "^7.6.11",

parser/Dockerfile

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,20 @@ RUN --mount=type=cache,target=/usr/local/cargo/git \
1717
wasm-pack build --target nodejs --release && rm pkg/.gitignore
1818

1919
FROM scratch AS build_export
20-
COPY --from=build /parser/pkg /
20+
COPY --from=build /parser/pkg /
21+
22+
FROM rust:1.80.1 AS license
23+
24+
RUN --mount=type=cache,target=/usr/local/cargo/git \
25+
--mount=type=cache,target=/usr/local/cargo/registry \
26+
cargo install --version 0.6.4 cargo-about
27+
28+
WORKDIR /parser
29+
COPY Cargo* about* ./
30+
COPY src src
31+
RUN --mount=type=cache,target=/usr/local/cargo/git \
32+
--mount=type=cache,target=/usr/local/cargo/registry \
33+
cargo about generate -o THIRD-PARTY-LICENSES.html about.hbs
34+
35+
FROM scratch AS license_export
36+
COPY --from=license /parser/THIRD-PARTY-LICENSES.html /

parser/about.hbs

Lines changed: 70 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

parser/about.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
accepted = [
2+
"Apache-2.0",
3+
"MIT",
4+
"Unicode-DFS-2016"
5+
]

0 commit comments

Comments
 (0)