create-fluxstack 1.7.0 → 1.7.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.
@@ -239,6 +239,9 @@ MONITORING_ENABLED=true
239
239
  const startTime = Date.now()
240
240
 
241
241
  try {
242
+ // Pre-build checks (version sync, etc.)
243
+ await this.runPreBuildChecks()
244
+
242
245
  // Validate configuration
243
246
  await this.validateConfig()
244
247
 
@@ -330,6 +333,17 @@ MONITORING_ENABLED=true
330
333
  }
331
334
  }
332
335
 
336
+ private async runPreBuildChecks(): Promise<void> {
337
+ try {
338
+ // Import and run version sync silently
339
+ const { syncVersion } = await import("../utils/sync-version")
340
+ syncVersion(true) // Pass true for silent mode
341
+ } catch (error) {
342
+ // Silently handle pre-build check failures
343
+ // Don't fail the build for pre-build check failures
344
+ }
345
+ }
346
+
333
347
  private async validateConfig(): Promise<void> {
334
348
  // Validate build configuration
335
349
  if (!this.config.build.outDir) {
@@ -144,6 +144,7 @@ export class ProjectCreator {
144
144
  dev: "bun run core/cli/index.ts dev",
145
145
  "dev:frontend": "bun run core/cli/index.ts frontend",
146
146
  "dev:backend": "bun run core/cli/index.ts backend",
147
+ "sync-version": "bun run core/utils/sync-version.ts",
147
148
  build: "bun run core/cli/index.ts build",
148
149
  "build:frontend": "bun run core/cli/index.ts build:frontend",
149
150
  "build:backend": "bun run core/cli/index.ts build:backend",
@@ -26,7 +26,7 @@ function getPackageVersion(): string {
26
26
  /**
27
27
  * Update version.ts with the version from package.json
28
28
  */
29
- function updateVersionFile(version: string): void {
29
+ function updateVersionFile(version: string, silent = false): void {
30
30
  const versionPath = join(process.cwd(), 'core/utils/version.ts')
31
31
  const versionContent = `/**
32
32
  * FluxStack Framework Version
@@ -36,19 +36,25 @@ function updateVersionFile(version: string): void {
36
36
  export const FLUXSTACK_VERSION = '${version}'
37
37
  `
38
38
  writeFileSync(versionPath, versionContent)
39
- console.log(`✅ Updated version.ts to v${version}`)
39
+ if (!silent) {
40
+ console.log(`✅ Updated version.ts to v${version}`)
41
+ }
40
42
  }
41
43
 
42
44
  /**
43
45
  * Main sync function
44
46
  */
45
- function syncVersion(): void {
47
+ function syncVersion(silent = false): void {
46
48
  try {
47
49
  const packageVersion = getPackageVersion()
48
- updateVersionFile(packageVersion)
49
- console.log(`🔄 Version synchronized: v${packageVersion}`)
50
+ updateVersionFile(packageVersion, silent)
51
+ if (!silent) {
52
+ console.log(`🔄 Version synchronized: v${packageVersion}`)
53
+ }
50
54
  } catch (error) {
51
- console.error('❌ Failed to sync version:', error)
55
+ if (!silent) {
56
+ console.error('❌ Failed to sync version:', error)
57
+ }
52
58
  process.exit(1)
53
59
  }
54
60
  }
@@ -3,4 +3,4 @@
3
3
  * Single source of truth for version number
4
4
  * Auto-synced with package.json
5
5
  */
6
- export const FLUXSTACK_VERSION = '1.7.0'
6
+ export const FLUXSTACK_VERSION = '1.7.3'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-fluxstack",
3
- "version": "1.7.0",
3
+ "version": "1.7.3",
4
4
  "description": "⚡ Revolutionary full-stack TypeScript framework with Declarative Config System, Elysia + React + Bun",
5
5
  "keywords": [
6
6
  "framework",
@@ -30,8 +30,7 @@
30
30
  "dev:coordinated": "concurrently --prefix {name} --names BACKEND,VITE --prefix-colors blue,green --kill-others-on-fail \"bun --watch app/server/index.ts\" \"vite --config vite.config.ts\"",
31
31
 
32
32
  "sync-version": "bun run core/utils/sync-version.ts",
33
- "prebuild": "bun run scripts/prebuild.ts",
34
- "build": "bun run prebuild && cross-env NODE_ENV=production bun run core/cli/index.ts build",
33
+ "build": "cross-env NODE_ENV=production bun run core/cli/index.ts build",
35
34
  "build:frontend": "vite build --config vite.config.ts --emptyOutDir",
36
35
  "build:backend": "bun run core/cli/index.ts build:backend",
37
36
  "start": "bun run core/cli/index.ts start",