@smoothbricks/cli 0.11.11 → 0.11.12
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/dist/monorepo/cargo-policy.d.ts +25 -1
- package/dist/monorepo/cargo-policy.d.ts.map +1 -1
- package/dist/monorepo/cargo-policy.js +396 -4
- package/dist/monorepo/index.d.ts.map +1 -1
- package/dist/monorepo/index.js +5 -1
- package/dist/monorepo/packs/index.d.ts.map +1 -1
- package/dist/monorepo/packs/index.js +13 -0
- package/managed/raw/tooling/direnv/devenv.smoo.nix +6 -0
- package/package.json +2 -2
- package/src/monorepo/cargo-policy.test.ts +206 -3
- package/src/monorepo/cargo-policy.ts +341 -2
- package/src/monorepo/index.ts +5 -1
- package/src/monorepo/packs/index.test.ts +32 -0
- package/src/monorepo/packs/index.ts +13 -0
|
@@ -2,6 +2,7 @@ import { chmodSync, existsSync, statSync } from 'node:fs';
|
|
|
2
2
|
import { join } from 'node:path';
|
|
3
3
|
import { printCommandOutput, runResult, runStatus } from '../../lib/run.js';
|
|
4
4
|
import { type ProjectTargets, readProjectTargets } from '../../nx/index.js';
|
|
5
|
+
import { applyCargoFeatureUnification, validateCargoCachePolicy } from '../cargo-policy.js';
|
|
5
6
|
import { validateGoToolchainAgreement } from '../go-toolchain.js';
|
|
6
7
|
import { syncBunLockfileVersions, validateBunLockfileVersions } from '../lockfile.js';
|
|
7
8
|
import { validateDevenvModuleImport, warnOnManagedFileDrift } from '../managed-files.js';
|
|
@@ -120,6 +121,18 @@ const packs: MonorepoPack[] = [
|
|
|
120
121
|
return validateDevenvModuleImport(ctx.root);
|
|
121
122
|
},
|
|
122
123
|
},
|
|
124
|
+
{
|
|
125
|
+
// Cargo's build-cache and feature-unification conventions. `--fix` writes
|
|
126
|
+
// the workspace feature unification a multi-crate workspace needs; the rest
|
|
127
|
+
// of the policy is a verdict a human has to act on.
|
|
128
|
+
name: 'cargo',
|
|
129
|
+
fixPreBuild(ctx) {
|
|
130
|
+
applyCargoFeatureUnification(ctx.root);
|
|
131
|
+
},
|
|
132
|
+
validatePreBuild(ctx) {
|
|
133
|
+
return validateCargoCachePolicy(ctx.root);
|
|
134
|
+
},
|
|
135
|
+
},
|
|
123
136
|
{
|
|
124
137
|
name: 'publishing',
|
|
125
138
|
init(ctx) {
|