@martel/calyx 1.2.2 → 1.2.4

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,17 @@
1
+ ## [1.2.4](https://github.com/bmartel/calyx/compare/v1.2.3...v1.2.4) (2026-07-01)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * make scaffolded project port dynamically read process.env.PORT ([3fbf8a6](https://github.com/bmartel/calyx/commit/3fbf8a6cb4a6be7a0bf8056bbe5fc391d9f77e97))
7
+
8
+ ## [1.2.3](https://github.com/bmartel/calyx/compare/v1.2.2...v1.2.3) (2026-07-01)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * dynamically read own package version for generated project dependencies ([3d55944](https://github.com/bmartel/calyx/commit/3d559443e9969638d68769bf9e127ac88df934c9))
14
+
1
15
  ## [1.2.2](https://github.com/bmartel/calyx/compare/v1.2.1...v1.2.2) (2026-07-01)
2
16
 
3
17
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@martel/calyx",
3
- "version": "1.2.2",
3
+ "version": "1.2.4",
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,
@@ -234,8 +247,9 @@ import { AppModule } from './app.module';
234
247
 
235
248
  async function bootstrap() {
236
249
  const app = await CalyxFactory.create(AppModule);
237
- await app.listen(3000);
238
- console.log('Application is running on http://localhost:3000');
250
+ const port = process.env.PORT || 3000;
251
+ await app.listen(port);
252
+ console.log(\`Application is running on http://localhost:\${port}\`);
239
253
  }
240
254
  bootstrap();
241
255
  `;