@dotenvx/dotenvx 3.0.0-beta.2 → 3.0.0-rc1
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/README.md +44 -32
- package/package.json +9 -9
package/README.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
# dotenvx Node.js SDK
|
|
1
|
+
# dotenvx Node.js SDK
|
|
2
2
|
|
|
3
3
|
The Node.js adapter for Forge's shared Rust `dotenvx-sdk`. Parsing, expansion,
|
|
4
|
-
decryption, source selection, custody delegation, and
|
|
4
|
+
decryption, source selection, custody delegation, and Dotenv.toml policy use
|
|
5
5
|
the same engine as Ruby and Python. JavaScript owns the public API, environment
|
|
6
6
|
updates, diagnostics, and output interception.
|
|
7
7
|
|
|
@@ -17,7 +17,10 @@ npm run test:dotenvx-nodejs
|
|
|
17
17
|
To install the local prototype in another project, pack and install the main
|
|
18
18
|
and matching platform packages together as described below.
|
|
19
19
|
|
|
20
|
-
The package keeps the `@dotenvx/dotenvx` name and
|
|
20
|
+
The package keeps the `@dotenvx/dotenvx` name and uses normal `0.4.x` versions
|
|
21
|
+
published under `next`. Install a specific version with
|
|
22
|
+
`npm install @dotenvx/dotenvx@0.4.11`, or follow Forge releases with
|
|
23
|
+
`npm install @dotenvx/dotenvx@next`. Unqualified installs continue to use `latest`.
|
|
21
24
|
There are no install-time downloads or compilation hooks. A local build writes
|
|
22
25
|
the current platform’s addon and default CLI to `native/` and prepares its npm
|
|
23
26
|
package under `dist/npm/`. The main npm package contains JavaScript only; native
|
|
@@ -79,7 +82,7 @@ in the internal keyring and are not injected into the application's environment.
|
|
|
79
82
|
When using a custom `processEnv`, include the PATH and provider settings it needs.
|
|
80
83
|
Secret reference resolution is opt-in with `resolveReferences: true`.
|
|
81
84
|
|
|
82
|
-
|
|
85
|
+
Dotenv.toml redaction is installed before diagnostics and injection. Console
|
|
83
86
|
output and stream writes are protected, including secrets split between writes.
|
|
84
87
|
|
|
85
88
|
## npm CLI
|
|
@@ -163,7 +166,7 @@ can be skipped with npm's `--offline` flag:
|
|
|
163
166
|
npm run build:dotenvx-nodejs
|
|
164
167
|
npm pack ./dotenvx-nodejs/dist/npm/dotenvx-darwin-arm64 --ignore-scripts
|
|
165
168
|
npm pack ./dotenvx-nodejs --ignore-scripts
|
|
166
|
-
npm install --offline ./dotenvx-dotenvx-
|
|
169
|
+
npm install --offline ./dotenvx-dotenvx-0.4.11.tgz ./dotenvx-dotenvx-darwin-arm64-0.4.11.tgz
|
|
167
170
|
```
|
|
168
171
|
|
|
169
172
|
Substitute the current platform package and version. A direct local directory
|
|
@@ -175,34 +178,43 @@ under `next`, waits for npm to serve all eight exact versions, then prepares and
|
|
|
175
178
|
tests the core `@dotenvx/dotenvx` wrapper across all eight platforms before
|
|
176
179
|
publishing it under `next`. **Existing `latest` tags stay unchanged.** The source
|
|
177
180
|
core package stays private; only the validated staged wrapper is publishable.
|
|
178
|
-
|
|
181
|
+
Releases accept exact SemVer versions, including `3.0.0-rc0`. Prereleases use
|
|
182
|
+
`next` and leave `latest` untouched.
|
|
179
183
|
|
|
180
|
-
From a clean working tree, prepare
|
|
184
|
+
From a clean working tree, prepare a Node.js release with:
|
|
181
185
|
|
|
182
186
|
```sh
|
|
183
187
|
npm run version:nodejs patch
|
|
188
|
+
# Or prepare an explicit release candidate:
|
|
189
|
+
npm run version:nodejs 3.0.0-rc0
|
|
184
190
|
```
|
|
185
191
|
|
|
186
|
-
|
|
187
|
-
`3.0.0-beta.1`, retaining the `3.0.0` release target. The helper synchronizes the
|
|
192
|
+
`patch`, `minor`, and `major` perform normal version bumps. The helper synchronizes
|
|
188
193
|
npm/platform dependency versions, lockfile, and adapter Cargo versions, then
|
|
189
194
|
creates a local commit and `nodejs-v<version>` tag. It does not publish or push.
|
|
190
195
|
You can also include `nodejs` in `npm run version:batch -- cli,nodejs patch`
|
|
191
|
-
(with optional `--push`).
|
|
192
|
-
`nodejs` is selected; `patch` still advances only the beta counter.
|
|
193
|
-
It prints the exact atomic push command for that commit and tag, for example:
|
|
196
|
+
(with optional `--push`). It prints the exact atomic push command, for example:
|
|
194
197
|
|
|
195
198
|
```sh
|
|
196
|
-
git push --atomic origin HEAD refs/tags/nodejs-
|
|
199
|
+
git push --atomic origin HEAD refs/tags/nodejs-v0.4.12
|
|
197
200
|
```
|
|
198
201
|
|
|
199
|
-
Pushing the
|
|
200
|
-
|
|
201
|
-
`
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
202
|
+
Pushing the matching tag triggers the full platform-and-core release under `next`.
|
|
203
|
+
To backfill or retry an existing release, dispatch the workflow
|
|
204
|
+
from `main`, enter the exact version (for example `0.4.11`), choose
|
|
205
|
+
`target=platforms`, and enable `publish`. Every job checks out the corresponding
|
|
206
|
+
`nodejs-v0.4.11` tag, whose package version must match. The tag must exist;
|
|
207
|
+
CLI-only `cli-v*` tags cannot be used for this flow. The matching Node.js tag
|
|
208
|
+
must contain these release scripts and guards.
|
|
209
|
+
|
|
210
|
+
```sh
|
|
211
|
+
gh workflow run nodejs.yml --ref main -f target=platforms -f version=0.4.11 -f publish=true
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
Manual runs default to `publish=false` for build and test checks. Existing
|
|
215
|
+
`latest` tags remain untouched. Already published versions are reused only when
|
|
216
|
+
tarball integrity matches. A platform publication or core test failure stops the
|
|
217
|
+
release before core publication. Published npm versions cannot be overwritten.
|
|
206
218
|
|
|
207
219
|
Before the first release, configure npm trusted publishing for
|
|
208
220
|
every platform package: repository `dotenvx/forge`, workflow `nodejs.yml`,
|
|
@@ -215,15 +227,15 @@ workflow now uses trusted publishing only and does not read an `NPM_TOKEN`
|
|
|
215
227
|
secret. No credentials are needed for build-only runs. Platform manifests also
|
|
216
228
|
set `publishConfig.tag` to `next`, and artifact validation rejects any other tag.
|
|
217
229
|
|
|
218
|
-
Forge owns the new
|
|
230
|
+
Forge owns the new `0.4.x` platform packages and core wrapper releases.
|
|
219
231
|
Existing 2.x versions remain unchanged.
|
|
220
232
|
|
|
221
233
|
|
|
222
|
-
## Core
|
|
234
|
+
## Core publication from Forge
|
|
223
235
|
|
|
224
236
|
Core publication follows successful platform publication automatically in
|
|
225
237
|
`nodejs.yml` tag releases. Preparation waits for npm's processing delay, then the
|
|
226
|
-
core test matrix must pass on all eight platforms. A separate `core
|
|
238
|
+
core test matrix must pass on all eight platforms. A separate `core` manual
|
|
227
239
|
mode remains available to test or retry only the wrapper. It uses the
|
|
228
240
|
already-published, exact-version platform packages. It never rebuilds or
|
|
229
241
|
republishes the CLI or native addons and never copies code to
|
|
@@ -245,17 +257,17 @@ To exercise the staged wrapper against the published native dependencies on all
|
|
|
245
257
|
eight targets, after committing and pushing the workflow changes, dispatch:
|
|
246
258
|
|
|
247
259
|
```sh
|
|
248
|
-
gh workflow run nodejs.yml --ref main -f target=core-
|
|
260
|
+
gh workflow run nodejs.yml --ref main -f target=core -f version=0.4.11 -f publish=false
|
|
249
261
|
```
|
|
250
262
|
|
|
251
263
|
The core test matrix installs the existing npm binaries and tests the actual
|
|
252
264
|
staged tarball, SDK imports, preload entry points, CLI dispatch, encryption, and
|
|
253
265
|
decryption. No Rust toolchain or native rebuild is used in core mode.
|
|
254
266
|
|
|
255
|
-
To publish or retry only the core
|
|
256
|
-
`main`, choose `target=core
|
|
257
|
-
|
|
258
|
-
versions are rejected. Publication waits for the full core test matrix and uses
|
|
267
|
+
To publish or retry only the core release, manually dispatch `nodejs.yml` from
|
|
268
|
+
`main`, choose `target=core`, enable `publish`, and enter the exact version
|
|
269
|
+
in the `version` input. All jobs check out its matching `nodejs-v<version>` tag.
|
|
270
|
+
Missing tags or mismatched package versions are rejected. Publication waits for the full core test matrix and uses
|
|
259
271
|
the `release` environment and GitHub OIDC, as do automatic tag releases.
|
|
260
272
|
The core package must trust
|
|
261
273
|
`dotenvx/forge`, workflow `nodejs.yml`, environment `release` on npm.
|
|
@@ -265,9 +277,9 @@ Only the validated `@dotenvx/dotenvx` tarball is published, with an explicit
|
|
|
265
277
|
provenance for this private repository. The publisher snapshots core/platform
|
|
266
278
|
tags, rechecks them before publication, and verifies them afterward. Only core's
|
|
267
279
|
`next` tag may change; `latest` and all platform tags must remain unchanged.
|
|
268
|
-
There is no
|
|
269
|
-
command in the core publisher. Existing versions are never overwritten. An
|
|
280
|
+
There is no `latest` publication option, platform-publish command, or dist-tag
|
|
281
|
+
mutation command in the core publisher. Existing versions are never overwritten. An
|
|
270
282
|
identical retry is accepted only if the published integrity and `next` tag match.
|
|
271
283
|
|
|
272
|
-
Both manual modes default to `publish=false`.
|
|
273
|
-
|
|
284
|
+
Both manual modes default to `publish=false`. Branch pushes do not publish;
|
|
285
|
+
matching `nodejs-v*` tag pushes publish platforms and core automatically.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dotenvx/dotenvx",
|
|
3
|
-
"version": "3.0.0-
|
|
3
|
+
"version": "3.0.0-rc1",
|
|
4
4
|
"description": "a secure dotenv—from the creator of dotenv",
|
|
5
5
|
"license": "BSD-3-Clause",
|
|
6
6
|
"homepage": "https://dotenvx.com",
|
|
@@ -60,14 +60,14 @@
|
|
|
60
60
|
"provenance": false
|
|
61
61
|
},
|
|
62
62
|
"optionalDependencies": {
|
|
63
|
-
"@dotenvx/dotenvx-darwin-arm64": "3.0.0-
|
|
64
|
-
"@dotenvx/dotenvx-darwin-x86_64": "3.0.0-
|
|
65
|
-
"@dotenvx/dotenvx-linux-x86_64": "3.0.0-
|
|
66
|
-
"@dotenvx/dotenvx-linux-arm64": "3.0.0-
|
|
67
|
-
"@dotenvx/dotenvx-linux-x86_64-musl": "3.0.0-
|
|
68
|
-
"@dotenvx/dotenvx-linux-arm64-musl": "3.0.0-
|
|
69
|
-
"@dotenvx/dotenvx-windows-x86_64": "3.0.0-
|
|
70
|
-
"@dotenvx/dotenvx-windows-arm64": "3.0.0-
|
|
63
|
+
"@dotenvx/dotenvx-darwin-arm64": "3.0.0-rc1",
|
|
64
|
+
"@dotenvx/dotenvx-darwin-x86_64": "3.0.0-rc1",
|
|
65
|
+
"@dotenvx/dotenvx-linux-x86_64": "3.0.0-rc1",
|
|
66
|
+
"@dotenvx/dotenvx-linux-arm64": "3.0.0-rc1",
|
|
67
|
+
"@dotenvx/dotenvx-linux-x86_64-musl": "3.0.0-rc1",
|
|
68
|
+
"@dotenvx/dotenvx-linux-arm64-musl": "3.0.0-rc1",
|
|
69
|
+
"@dotenvx/dotenvx-windows-x86_64": "3.0.0-rc1",
|
|
70
|
+
"@dotenvx/dotenvx-windows-arm64": "3.0.0-rc1"
|
|
71
71
|
},
|
|
72
72
|
"private": false
|
|
73
73
|
}
|