Skip to content

Commit 821484a

Browse files
authored
Merge branch 'NODE-6090' into NODE-6120
2 parents 2ac36d4 + 61564cd commit 821484a

File tree

463 files changed

+263930
-208
lines changed

Some content is hidden

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

463 files changed

+263930
-208
lines changed
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Compress and Sign
2+
description: 'Compresses package and signs with garasign'
3+
4+
inputs:
5+
aws_role_arn:
6+
description: 'AWS role input for drivers-github-tools/gpg-sign@v2'
7+
required: true
8+
aws_region_name:
9+
description: 'AWS region name input for drivers-github-tools/gpg-sign@v2'
10+
required: true
11+
aws_secret_id:
12+
description: 'AWS secret id input for drivers-github-tools/gpg-sign@v2'
13+
required: true
14+
npm_package_name:
15+
description: 'The name for the npm package this repository represents'
16+
required: true
17+
18+
runs:
19+
using: composite
20+
steps:
21+
- run: npm pack
22+
shell: bash
23+
24+
- name: Get release version and release package file name
25+
id: get_vars
26+
shell: bash
27+
run: |
28+
package_version=$(jq --raw-output '.version' package.json)
29+
echo "package_version=${package_version}" >> "$GITHUB_OUTPUT"
30+
echo "package_file=${{ inputs.npm_package_name }}-${package_version}.tgz" >> "$GITHUB_OUTPUT"
31+
32+
- name: Set up drivers-github-tools
33+
uses: mongodb-labs/drivers-github-tools/setup@v2
34+
with:
35+
aws_region_name: ${{ inputs.aws_region_name }}
36+
aws_role_arn: ${{ inputs.aws_role_arn }}
37+
aws_secret_id: ${{ inputs.aws_secret_id }}
38+
39+
- name: Create detached signature
40+
uses: mongodb-labs/drivers-github-tools/gpg-sign@v2
41+
with:
42+
filenames: ${{ steps.get_vars.outputs.package_file }}
43+
env:
44+
RELEASE_ASSETS: ${{ steps.get_vars.outputs.package_file }}.temp.sig
45+
46+
- name: Name release asset correctly
47+
run: mv ${{ steps.get_vars.outputs.package_file }}.temp.sig ${{ steps.get_vars.outputs.package_file }}.sig
48+
shell: bash
49+
50+
- name: "Upload release artifacts"
51+
run: gh release upload v${{ steps.get_vars.outputs.package_version }} ${{ steps.get_vars.outputs.package_file }}.sig
52+
shell: bash
53+
env:
54+
GH_TOKEN: ${{ github.token }}

.github/workflows/release-5.x.yml

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,21 +11,32 @@ permissions:
1111
name: release-5x
1212

1313
jobs:
14-
release-please:
14+
release_please:
1515
runs-on: ubuntu-latest
16+
outputs:
17+
release_created: ${{ steps.release.outputs.release_created }}
1618
steps:
1719
- id: release
18-
uses: google-github-actions/release-please-action@v4
20+
uses: googleapis/release-please-action@v4
1921
with:
2022
target-branch: 5.x
21-
22-
# If release-please created a release, publish to npm
23-
- if: ${{ steps.release.outputs.release_created }}
24-
uses: actions/checkout@v4
25-
- if: ${{ steps.release.outputs.release_created }}
26-
name: actions/setup
23+
24+
compress_sign_and_upload:
25+
needs: [release_please]
26+
if: ${{ needs.release_please.outputs.release_created }}
27+
environment: release
28+
runs-on: ubuntu-latest
29+
steps:
30+
- uses: actions/checkout@v4
31+
- name: actions/setup
2732
uses: ./.github/actions/setup
28-
- if: ${{ steps.release.outputs.release_created }}
29-
run: npm publish --provenance --tag=5x
33+
- name: actions/compress_sign_and_upload
34+
uses: ./.github/actions/compress_sign_and_upload
35+
with:
36+
aws_role_arn: ${{ secrets.AWS_ROLE_ARN }}
37+
aws_region_name: 'us-east-1'
38+
aws_secret_id: ${{ secrets.AWS_SECRET_ID }}
39+
npm_package_name: 'mongodb'
40+
- run: npm publish --provenance --tag=5x
3041
env:
3142
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/release.yml

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,30 @@ permissions:
1111
name: release
1212

1313
jobs:
14-
release-please:
14+
release_please:
1515
runs-on: ubuntu-latest
16+
outputs:
17+
release_created: ${{ steps.release.outputs.release_created }}
1618
steps:
1719
- id: release
1820
uses: googleapis/release-please-action@v4
1921

20-
# If release-please created a release, publish to npm
21-
- if: ${{ steps.release.outputs.release_created }}
22-
uses: actions/checkout@v4
23-
- if: ${{ steps.release.outputs.release_created }}
24-
name: actions/setup
22+
compress_sign_and_upload:
23+
needs: [release_please]
24+
if: ${{ needs.release_please.outputs.release_created }}
25+
environment: release
26+
runs-on: ubuntu-latest
27+
steps:
28+
- uses: actions/checkout@v4
29+
- name: actions/setup
2530
uses: ./.github/actions/setup
26-
- if: ${{ steps.release.outputs.release_created }}
27-
run: npm publish --provenance
31+
- name: actions/compress_sign_and_upload
32+
uses: ./.github/actions/compress_sign_and_upload
33+
with:
34+
aws_role_arn: ${{ secrets.AWS_ROLE_ARN }}
35+
aws_region_name: 'us-east-1'
36+
aws_secret_id: ${{ secrets.AWS_SECRET_ID }}
37+
npm_package_name: 'mongodb'
38+
- run: npm publish --provenance
2839
env:
2940
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,25 @@ The official [MongoDB](https://www.mongodb.com/) driver for Node.js.
2020
| Contributing | [CONTRIBUTING.md](https://github.com/mongodb/node-mongodb-native/blob/HEAD/CONTRIBUTING.md) |
2121
| Changelog | [HISTORY.md](https://github.com/mongodb/node-mongodb-native/blob/HEAD/HISTORY.md) |
2222

23+
24+
25+
### Release Integrity
26+
27+
The GitHub release contains a detached signature file for the NPM package (named
28+
`mongodb-X.Y.Z.tgz.sig`).
29+
30+
The following command returns the link npm package.
31+
```shell
32+
npm view [email protected] dist.tarball
33+
```
34+
35+
Using the result of the above command, a `curl` command can return the official npm package for the release.
36+
37+
To verify the integrity of the downloaded package, run the following command:
38+
```shell
39+
gpg --verify mongodb-X.Y.Z.tgz.sig mongodb-X.Y.Z.tgz
40+
```
41+
2342
### Bugs / Feature Requests
2443

2544
Think you’ve found a bug? Want to see a new feature in `node-mongodb-native`? Please open a

docs/6.7/.nojekyll

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false.

docs/6.7/assets/highlight.css

Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
:root {
2+
--light-hl-0: #795E26;
3+
--dark-hl-0: #DCDCAA;
4+
--light-hl-1: #000000;
5+
--dark-hl-1: #D4D4D4;
6+
--light-hl-2: #A31515;
7+
--dark-hl-2: #CE9178;
8+
--light-hl-3: #0000FF;
9+
--dark-hl-3: #569CD6;
10+
--light-hl-4: #008000;
11+
--dark-hl-4: #6A9955;
12+
--light-hl-5: #0070C1;
13+
--dark-hl-5: #4FC1FF;
14+
--light-hl-6: #001080;
15+
--dark-hl-6: #9CDCFE;
16+
--light-hl-7: #AF00DB;
17+
--dark-hl-7: #C586C0;
18+
--light-hl-8: #098658;
19+
--dark-hl-8: #B5CEA8;
20+
--light-hl-9: #267F99;
21+
--dark-hl-9: #4EC9B0;
22+
--light-hl-10: #000000;
23+
--dark-hl-10: #C8C8C8;
24+
--light-hl-11: #811F3F;
25+
--dark-hl-11: #D16969;
26+
--light-hl-12: #000000FF;
27+
--dark-hl-12: #D4D4D4;
28+
--light-hl-13: #EE0000;
29+
--dark-hl-13: #D7BA7D;
30+
--light-code-background: #FFFFFF;
31+
--dark-code-background: #1E1E1E;
32+
}
33+
34+
@media (prefers-color-scheme: light) { :root {
35+
--hl-0: var(--light-hl-0);
36+
--hl-1: var(--light-hl-1);
37+
--hl-2: var(--light-hl-2);
38+
--hl-3: var(--light-hl-3);
39+
--hl-4: var(--light-hl-4);
40+
--hl-5: var(--light-hl-5);
41+
--hl-6: var(--light-hl-6);
42+
--hl-7: var(--light-hl-7);
43+
--hl-8: var(--light-hl-8);
44+
--hl-9: var(--light-hl-9);
45+
--hl-10: var(--light-hl-10);
46+
--hl-11: var(--light-hl-11);
47+
--hl-12: var(--light-hl-12);
48+
--hl-13: var(--light-hl-13);
49+
--code-background: var(--light-code-background);
50+
} }
51+
52+
@media (prefers-color-scheme: dark) { :root {
53+
--hl-0: var(--dark-hl-0);
54+
--hl-1: var(--dark-hl-1);
55+
--hl-2: var(--dark-hl-2);
56+
--hl-3: var(--dark-hl-3);
57+
--hl-4: var(--dark-hl-4);
58+
--hl-5: var(--dark-hl-5);
59+
--hl-6: var(--dark-hl-6);
60+
--hl-7: var(--dark-hl-7);
61+
--hl-8: var(--dark-hl-8);
62+
--hl-9: var(--dark-hl-9);
63+
--hl-10: var(--dark-hl-10);
64+
--hl-11: var(--dark-hl-11);
65+
--hl-12: var(--dark-hl-12);
66+
--hl-13: var(--dark-hl-13);
67+
--code-background: var(--dark-code-background);
68+
} }
69+
70+
:root[data-theme='light'] {
71+
--hl-0: var(--light-hl-0);
72+
--hl-1: var(--light-hl-1);
73+
--hl-2: var(--light-hl-2);
74+
--hl-3: var(--light-hl-3);
75+
--hl-4: var(--light-hl-4);
76+
--hl-5: var(--light-hl-5);
77+
--hl-6: var(--light-hl-6);
78+
--hl-7: var(--light-hl-7);
79+
--hl-8: var(--light-hl-8);
80+
--hl-9: var(--light-hl-9);
81+
--hl-10: var(--light-hl-10);
82+
--hl-11: var(--light-hl-11);
83+
--hl-12: var(--light-hl-12);
84+
--hl-13: var(--light-hl-13);
85+
--code-background: var(--light-code-background);
86+
}
87+
88+
:root[data-theme='dark'] {
89+
--hl-0: var(--dark-hl-0);
90+
--hl-1: var(--dark-hl-1);
91+
--hl-2: var(--dark-hl-2);
92+
--hl-3: var(--dark-hl-3);
93+
--hl-4: var(--dark-hl-4);
94+
--hl-5: var(--dark-hl-5);
95+
--hl-6: var(--dark-hl-6);
96+
--hl-7: var(--dark-hl-7);
97+
--hl-8: var(--dark-hl-8);
98+
--hl-9: var(--dark-hl-9);
99+
--hl-10: var(--dark-hl-10);
100+
--hl-11: var(--dark-hl-11);
101+
--hl-12: var(--dark-hl-12);
102+
--hl-13: var(--dark-hl-13);
103+
--code-background: var(--dark-code-background);
104+
}
105+
106+
.hl-0 { color: var(--hl-0); }
107+
.hl-1 { color: var(--hl-1); }
108+
.hl-2 { color: var(--hl-2); }
109+
.hl-3 { color: var(--hl-3); }
110+
.hl-4 { color: var(--hl-4); }
111+
.hl-5 { color: var(--hl-5); }
112+
.hl-6 { color: var(--hl-6); }
113+
.hl-7 { color: var(--hl-7); }
114+
.hl-8 { color: var(--hl-8); }
115+
.hl-9 { color: var(--hl-9); }
116+
.hl-10 { color: var(--hl-10); }
117+
.hl-11 { color: var(--hl-11); }
118+
.hl-12 { color: var(--hl-12); }
119+
.hl-13 { color: var(--hl-13); }
120+
pre, code { background: var(--code-background); }

docs/6.7/assets/main.js

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

docs/6.7/assets/search.js

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

0 commit comments

Comments
 (0)