@dbx-tools/projen 0.9.17 → 0.9.18

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 CHANGED
@@ -233,16 +233,14 @@ branch that already contains released `main`, and merges `main` into a diverged
233
233
  branch when the merge is conflict-free. Missing branches and conflicted merges
234
234
  are left untouched.
235
235
 
236
- Rust release generation creates separate UniFFI and binary matrices with one row
237
- per target. A UniFFI row builds all discovered binding packages together. A
238
- binary row builds all selected release binaries in one Cargo invocation with
239
- the union of their required features, so a feature-gated companion does not
240
- trigger a second compile graph. Each matrix has its own source-scoped
241
- fingerprint, raw bundle, and Cargo cache namespace. Set a source-only crate's or
242
- release-enabled binary's `releaseExcludeOs` package option to omit it from
243
- incompatible binary rows. Release binary packaging and artifact upload are
244
- skipped in those rows. UniFFI crates cannot use this option because every
245
- configured target must produce their artifacts.
236
+ Rust release generation creates one uncached matrix with one row per target.
237
+ Each row builds all discovered bindings and selected release binaries together
238
+ with the union of their required features, then packages every native artifact
239
+ from that one Cargo output. Set a source-only crate's or release-enabled
240
+ binary's `releaseExcludeOs` package option to omit it from incompatible rows.
241
+ Release binary packaging and artifact upload are skipped in those rows. UniFFI
242
+ crates cannot use this option because every configured target must produce
243
+ their artifacts.
246
244
  Set a release binary's `cli` package option and the workspace
247
245
  `cliRegistryPath` to generate a typed `dbx` command registry from the same
248
246
  selected targets. The generated entries carry only the archives that the
@@ -254,18 +252,12 @@ archives and Python wheels; they do not install Bun or UBRN and do not build
254
252
  Node facades. A binary-only row therefore installs no language package tool.
255
253
  `rustVersion` remains the MSRV recorded in package manifests, while
256
254
  `releaseRustVersion` independently defaults release compilation to `stable`.
257
- Stable Windows rows verify and use the hosted runner's installed Rust toolchain
258
- and select `rust-lld` for compilation. Rust release rows restore and update
259
- dependency-only Cargo caches in the release branch's category-and-target cache
260
- scope. The cache key excludes workspace version changes, and manual tag recovery
261
- restores without saving a tag-scoped copy. There is no separate cache workflow
262
- or sccache layer. After publishing the current raw Rust bundles and build manifests,
263
- the GitHub release job deletes those internal assets from published
264
- `vMAJOR.MINOR.PATCH` releases strictly lower than the current version while
265
- leaving versioned consumer binaries in place. Phase timings are written to each
266
- build log. Python generation executes the already-built
267
- `target/<triple>/release/<crate>-uniffi-bindgen` directly. Artifact packaging
268
- therefore does no Rust compilation after the UniFFI build.
255
+ Rows use the target runner's standard Rust toolchain without sccache, Cargo
256
+ cache actions, source fingerprints, or reusable raw bundles. Phase timings are
257
+ written to each build log. GitHub-hosted Python generation executes the
258
+ already-built `target/<triple>/release/<crate>-uniffi-bindgen` directly. A local
259
+ macOS build compiles one host generator and reuses it while packaging the
260
+ Darwin, Linux, and Windows libraries.
269
261
 
270
262
  Artifacts identify their crate, target, and type. Rust jobs publish non-private
271
263
  Cargo crates with `cargo publish --no-verify` and upload requested binary assets
@@ -282,6 +274,16 @@ architecture. Omit both filters to regenerate the complete maintained matrix.
282
274
  `DBX_TOOLS_RELEASE_PLATFORMS` can select the generated matrix without repeating
283
275
  environment parsing in a consumer.
284
276
 
277
+ `bun run release --build auto` is the default. It selects a local build when
278
+ the chosen GitHub CLI account has maintain/admin access, the host is macOS, and
279
+ Cargo, Zig, cargo-zigbuild, cargo-xwin, LLVM, uv, and zip are available.
280
+ Otherwise it selects the GitHub matrix. `--build local` and `--build remote`
281
+ force the choice. Local mode builds the exact merged release SHA and uploads
282
+ the archives plus a checksum manifest to the draft GitHub Release before
283
+ registry publication continues. A manager can rerun an interrupted upload with
284
+ `bun run release:assets --version <version> --tag <tag> --upload` from the
285
+ matching release source.
286
+
285
287
  Public UniFFI facades are marked with `dbxToolsConfig.uniffi = true` in Node
286
288
  manifests and `[tool.dbx_tools.config] uniffi = true` in Python manifests. The
287
289
  Node jobs consume same-run artifacts, publish native archives first with npm
@@ -483,14 +485,15 @@ bootstrap a folder that has no `.projenrc.ts` or toolchain yet.
483
485
 
484
486
  ## Run Tasks From The ROOT
485
487
 
486
- Every repo-wide task lives on the root, and the root's `compile` / `test`
487
- delegate with `bun run --filter '*'` rather than emitting a step per member - so
488
- a new package is covered without a re-synth. Work from the root:
488
+ Every repo-wide task lives on the root. `compile` batches ordinary TypeScript
489
+ packages in up to four `tsc --build` processes and runs custom compile tasks alongside them;
490
+ `test` delegates with `bun run --filter '*'`. Both read the current workspace
491
+ list, so a new package is covered without a re-synth. Work from the root:
489
492
 
490
493
  | Task | What it does |
491
494
  | ------------------------------ | ---------------------------------------------------- |
492
495
  | `bun run build` | synth + workspace compile and tests |
493
- | `bun run compile` | `tsc --build` in each member, in parallel |
496
+ | `bun run compile` | Batched `tsc --build` plus custom member compiles |
494
497
  | `bun run test` | `eslint` once, then each member's tests |
495
498
  | `bun run sync` | re-synth (`--watch` to keep synthing) |
496
499
  | `bun run barrels` | regenerate the read-only `index.ts` barrels |
package/index.ts CHANGED
@@ -3,7 +3,7 @@
3
3
  // Hand edits are overwritten on the next watch; this file is read-only.
4
4
 
5
5
  export const PACKAGE_IDENTIFIER = "@dbx-tools/projen";
6
- export const PACKAGE_VERSION = "0.9.17";
6
+ export const PACKAGE_VERSION = "0.9.18";
7
7
  export * as barrels from "./src/barrels.ts";
8
8
  export * as bunApp from "./src/bun-app.ts";
9
9
  export * as bunWorkflow from "./src/bun-workflow.ts";
@@ -66,7 +66,7 @@ export { DBXToolsReleaseCatalog } from "./src/release-catalog.ts";
66
66
  export type { DBXToolsVersioningMode, ReleaseProjectLanguage, ReleaseArtifactKind, ReleaseEdgeKind, ReleasePropagation, ReleaseUnitRule, DBXToolsReleaseCatalogOptions, ReleaseDependencyInput, ReleaseProjectRegistration, ExternalReleaseProjectRegistration, ReleaseArtifactRegistration, ReleaseProjectNode, ReleaseArtifact, ReleaseDependencyEdge, ReleaseUnit, ReleaseUnitGraph } from "./src/release-catalog.ts";
67
67
  export { RELEASE_TAG, RELEASE_SHA, RELEASE_VERSION, RELEASE_SUMMARY_DIRECTORY, RELEASE_SUMMARY_PROVIDER_NAMES, RELEASE_SUMMARY_FILE } from "./src/release-dispatch.ts";
68
68
  export type { ReleaseSummaryProviderName } from "./src/release-dispatch.ts";
69
- export type { GithubRepositoryIdentity, GithubAuthenticatedAccount } from "./src/release-github.ts";
69
+ export type { GithubRepositoryIdentity, GithubAuthenticatedAccount, GithubRepositoryPermissions } from "./src/release-github.ts";
70
70
  export type { ReleaseReason, PlannedReleaseUnit, PlannedPackage, PlannedArtifact, PlannedRustTarget, ReleasePlan } from "./src/release-plan.ts";
71
71
  export { ReleaseUnitWorkspacePlugin } from "./src/release-please.ts";
72
72
  export type { ReleaseUnitWorkspacePluginOptions } from "./src/release-please.ts";
package/package.json CHANGED
@@ -2,7 +2,6 @@
2
2
  "name": "@dbx-tools/projen",
3
3
  "scripts": {
4
4
  "build": "projen build",
5
- "bundle:rust-release": "projen bundle:rust-release",
6
5
  "clobber": "projen clobber",
7
6
  "compile": "projen compile",
8
7
  "default": "projen default",
@@ -30,9 +29,9 @@
30
29
  },
31
30
  "dependencies": {
32
31
  "@clack/prompts": "^1.7.0",
33
- "@dbx-tools/core": "^0.9.17",
34
- "@dbx-tools/path": "^0.9.17",
35
- "@dbx-tools/shared-core": "^0.9.17",
32
+ "@dbx-tools/core": "^0.9.18",
33
+ "@dbx-tools/path": "^0.9.18",
34
+ "@dbx-tools/shared-core": "^0.9.18",
36
35
  "commander": "^15.0.0",
37
36
  "concurrently": "^10.0.3",
38
37
  "constructs": "^10.6.0",
@@ -53,7 +52,7 @@
53
52
  },
54
53
  "main": "index.ts",
55
54
  "license": "Apache-2.0",
56
- "version": "0.9.17",
55
+ "version": "0.9.18",
57
56
  "types": "index.ts",
58
57
  "type": "module",
59
58
  "exports": {
@@ -22,6 +22,16 @@ export type ReleaseArch = (typeof RELEASE_ARCHES)[number];
22
22
 
23
23
  export type { VersionLevel } from "./workspace-version.ts";
24
24
 
25
+ /** Stable archive name for one native release binary. */
26
+ export function releaseBinaryAssetName(
27
+ binaryName: string,
28
+ nodeTarget: string,
29
+ operatingSystem: ReleaseOs,
30
+ ): string {
31
+ const extension = operatingSystem === "win32" ? "zip" : "tar.gz";
32
+ return `${binaryName}-${nodeTarget}.${extension}`;
33
+ }
34
+
25
35
  function collectValue<T extends string>(value: T, previous: T[]): T[] {
26
36
  return [...previous, value];
27
37
  }
@@ -71,6 +71,8 @@ export interface RustCrateOptions {
71
71
  readonly release?: boolean;
72
72
  /** Omit this crate and any release binary artifact from these operating systems. */
73
73
  readonly releaseExcludeOs?: readonly RustReleaseOs[];
74
+ /** Cargo features used only by the macOS cross-platform release builder. */
75
+ readonly releaseLocalFeatures?: readonly string[];
74
76
  readonly dependencies?: Readonly<Record<string, CargoDependency>>;
75
77
  /** Cargo dependencies scoped by a target cfg expression. */
76
78
  readonly targetDependencies?: Readonly<Record<string, Readonly<Record<string, CargoDependency>>>>;
@@ -221,6 +223,7 @@ function packageOptions(
221
223
  ...(options.private !== undefined ? { private: options.private } : {}),
222
224
  ...(options.release !== undefined ? { release: options.release } : {}),
223
225
  ...(options.releaseExcludeOs ? { releaseExcludeOs: options.releaseExcludeOs } : {}),
226
+ ...(options.releaseLocalFeatures ? { releaseLocalFeatures: options.releaseLocalFeatures } : {}),
224
227
  ...(options.dependencies ? { dependencies: options.dependencies } : {}),
225
228
  ...(options.targetDependencies ? { targetDependencies: options.targetDependencies } : {}),
226
229
  ...(options.devDependencies ? { devDependencies: options.devDependencies } : {}),