@martel/calyx 1.2.2 → 1.2.3

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/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ ## [1.2.3](https://github.com/bmartel/calyx/compare/v1.2.2...v1.2.3) (2026-07-01)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * dynamically read own package version for generated project dependencies ([3d55944](https://github.com/bmartel/calyx/commit/3d559443e9969638d68769bf9e127ac88df934c9))
7
+
1
8
  ## [1.2.2](https://github.com/bmartel/calyx/compare/v1.2.1...v1.2.2) (2026-07-01)
2
9
 
3
10
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@martel/calyx",
3
- "version": "1.2.2",
3
+ "version": "1.2.3",
4
4
  "description": "High-performance Bun-native NestJS-compatible framework",
5
5
  "main": "src/index.ts",
6
6
  "bin": {
package/src/cli/index.ts CHANGED
@@ -108,9 +108,22 @@ function runNew(name: string) {
108
108
  mkdirSync(name, { recursive: true });
109
109
  mkdirSync(join(name, 'src'), { recursive: true });
110
110
 
111
- // Write package.json
112
111
  const isDevMode = process.env.CALYX_DEV === 'true';
113
- const calyxDependency = isDevMode ? "link:../.." : "^0.1.0";
112
+
113
+ let packageVersion = '0.1.0';
114
+ try {
115
+ const selfPkgPath = join(import.meta.dir, '../../package.json');
116
+ if (existsSync(selfPkgPath)) {
117
+ const selfPkg = JSON.parse(readFileSync(selfPkgPath, 'utf-8'));
118
+ if (selfPkg.version) {
119
+ packageVersion = selfPkg.version;
120
+ }
121
+ }
122
+ } catch {
123
+ // Fallback
124
+ }
125
+
126
+ const calyxDependency = isDevMode ? "link:../.." : `^${packageVersion}`;
114
127
 
115
128
  const packageJson = {
116
129
  name,