create-shallot 0.9.3 → 0.9.5
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/index.ts +8 -2
- package/package.json +9 -2
package/index.ts
CHANGED
|
@@ -1,8 +1,14 @@
|
|
|
1
1
|
#!/usr/bin/env bun
|
|
2
2
|
|
|
3
|
-
import { existsSync, mkdirSync, writeFileSync } from "fs";
|
|
3
|
+
import { existsSync, mkdirSync, readFileSync, writeFileSync } from "fs";
|
|
4
4
|
import { dirname, join, resolve } from "path";
|
|
5
5
|
|
|
6
|
+
// the scaffold pins @dylanebert/shallot to the scaffold's own version — lockstep-gated by
|
|
7
|
+
// check-versions.ts — so a stale scaffold can't install a newer engine whose peer ranges the
|
|
8
|
+
// typegpu/unplugin-typegpu pins no longer satisfy. tilde matches the sibling pins' intent (patch-only
|
|
9
|
+
// for 0.x) and shallot's 0.x cadence where each minor may break peers.
|
|
10
|
+
const shallotRange = `~${(JSON.parse(readFileSync(join(import.meta.dir, "package.json"), "utf8")) as { version: string }).version}`;
|
|
11
|
+
|
|
6
12
|
/**
|
|
7
13
|
* the project files keyed by relative path, with the project name interpolated. the single source of
|
|
8
14
|
* truth for `bun create shallot <name>`.
|
|
@@ -23,7 +29,7 @@ export function template(name: string): Record<string, string> {
|
|
|
23
29
|
version: "0.0.0",
|
|
24
30
|
private: true,
|
|
25
31
|
type: "module",
|
|
26
|
-
dependencies: { "@dylanebert/shallot":
|
|
32
|
+
dependencies: { "@dylanebert/shallot": shallotRange, typegpu: "~0.12.0" },
|
|
27
33
|
devDependencies: { "unplugin-typegpu": "~0.12.1", typescript: "^7.0.2" },
|
|
28
34
|
},
|
|
29
35
|
null,
|
package/package.json
CHANGED
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-shallot",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.5",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"bin": "./index.ts",
|
|
6
6
|
"files": ["index.ts"],
|
|
7
7
|
"description": "Scaffold a Shallot project",
|
|
8
|
-
"license": "MIT"
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://github.com/dylanebert/shallot.git",
|
|
12
|
+
"directory": "packages/create-shallot"
|
|
13
|
+
},
|
|
14
|
+
"homepage": "https://github.com/dylanebert/shallot",
|
|
15
|
+
"bugs": "https://github.com/dylanebert/shallot/issues"
|
|
9
16
|
}
|