@xrystal/core 3.52.3 → 3.52.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/README.md CHANGED
@@ -3,25 +3,25 @@
3
3
  > **EN** — Microservice runtime: Express or Elysia HTTP, DI loaders, live `tmp.yml`, standardized API responses.
4
4
  > **TR** — Microservice runtime: Express veya Elysia HTTP, DI loader'lar, canlı `tmp.yml`, standart API cevapları.
5
5
 
6
- **CLI:** `xry` · **Version:** `3.52.3` · [npm](https://www.npmjs.com/package/@xrystal/core)
6
+ **CLI:** `xry` · **Version:** `3.52.4` · [npm](https://www.npmjs.com/package/@xrystal/core)
7
7
 
8
8
  ---
9
9
 
10
10
  ## Platform services / Platform servisleri
11
11
 
12
- **EN:** Consumer microservices in `../services/` — pin `@xrystal/core` to the latest published minor (currently **3.52.3**).
12
+ **EN:** Consumer microservices in `../services/` — pin `@xrystal/core` to the latest published minor (currently **3.52.4**).
13
13
 
14
- **TR:** `../services/` altındaki tüketen microservice'ler — `@xrystal/core` sürümünü npm latest ile hizala (şu an **3.52.3**).
14
+ **TR:** `../services/` altındaki tüketen microservice'ler — `@xrystal/core` sürümünü npm latest ile hizala (şu an **3.52.4**).
15
15
 
16
16
  | Repo folder | `tmp.yml` name | Role | Service pkg | `@xrystal/core` |
17
17
  |-------------|----------------|------|-------------|-----------------|
18
- | `api-core-svc` | `core` | Core domain API | `1.0.24` | `3.52.3` |
19
- | `api-cron-svc` | `crons` | Scheduled jobs / Kafka queue worker | `0.1.25` | `3.52.3` |
20
- | `api-gateway-svc` | `gateway` | Edge gateway, routing, cache, Mongo config | `2.0.49` | `3.52.3` |
21
- | `api-gpt-svc` | `gpt` | GPT / AI features | `1.0.22` | `3.52.3` |
22
- | `api-iam-svc` | `iam` | Identity & access management | `0.7.26` | `3.52.3` |
23
- | `api-log-svc` | `log` | Logging service | `1.0.20` | `3.52.3` |
24
- | `api-websocket-svc` | `websocket` | WebSocket / realtime | `0.8.31` | `3.52.3` |
18
+ | `api-core-svc` | `core` | Core domain API | `1.0.24` | `3.52.4` |
19
+ | `api-cron-svc` | `crons` | Scheduled jobs / Kafka queue worker | `0.1.25` | `3.52.4` |
20
+ | `api-gateway-svc` | `gateway` | Edge gateway, routing, cache, Mongo config | `2.0.49` | `3.52.4` |
21
+ | `api-gpt-svc` | `gpt` | GPT / AI features | `1.0.22` | `3.52.4` |
22
+ | `api-iam-svc` | `iam` | Identity & access management | `0.7.26` | `3.52.4` |
23
+ | `api-log-svc` | `log` | Logging service | `1.0.20` | `3.52.4` |
24
+ | `api-websocket-svc` | `websocket` | WebSocket / realtime | `0.8.31` | `3.52.4` |
25
25
 
26
26
  **SSL / TLS helpers** (since 3.49.0): import from loader subpaths, not `@xrystal/core/utils`:
27
27
 
@@ -35,7 +35,7 @@ import { resolveMongoConnectOptions } from '@xrystal/core/loader/mongo'
35
35
 
36
36
  ```bash
37
37
  cd ../services/api-<name>-svc
38
- bun add @xrystal/core@3.52.3
38
+ bun add @xrystal/core@3.52.4
39
39
  bun run build
40
40
  ```
41
41
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "author": "Yusuf Yasir KAYGUSUZ",
3
3
  "name": "@xrystal/core",
4
- "version": "3.52.3",
4
+ "version": "3.52.4",
5
5
  "description": "microservice runtime library",
6
6
  "publishConfig": {
7
7
  "access": "public",
@@ -2,7 +2,7 @@ import { execSync } from 'node:child_process'
2
2
  import fs from 'node:fs'
3
3
  import path from 'node:path'
4
4
 
5
- import { getRuntimeTooling, detectCliHostRuntime } from './cli-runtime.mjs'
5
+ import { getRuntimeTooling, resolveProjectRuntime } from './cli-runtime.mjs'
6
6
  import { packageDefaults } from './package-defaults.mjs'
7
7
 
8
8
  function readDeclaredCoreVersion(pkg) {
@@ -15,6 +15,17 @@ function normalizePinnedVersion(value) {
15
15
  return String(value ?? '').trim().replace(/^[\^~]/, '')
16
16
  }
17
17
 
18
+ function resolveProjectPackageManager(root) {
19
+ try {
20
+ return getRuntimeTooling(resolveProjectRuntime(root)).packageManager
21
+ } catch {
22
+ if (fs.existsSync(path.join(root, 'bun.lock')) || fs.existsSync(path.join(root, 'bun.lockb'))) return 'bun'
23
+ if (fs.existsSync(path.join(root, 'pnpm-lock.yaml'))) return 'pnpm'
24
+ if (fs.existsSync(path.join(root, 'yarn.lock'))) return 'yarn'
25
+ return 'npm'
26
+ }
27
+ }
28
+
18
29
  export function syncCoreDependency(root, targetVersion, { dryRun = false } = {}) {
19
30
  const pkgPath = path.join(root, 'package.json')
20
31
  if (!fs.existsSync(pkgPath)) {
@@ -40,7 +51,7 @@ export function syncCoreDependency(root, targetVersion, { dryRun = false } = {})
40
51
  return { synced: true, dryRun: true, declared, current, targetVersion }
41
52
  }
42
53
 
43
- const { packageManager } = getRuntimeTooling(detectCliHostRuntime())
54
+ const packageManager = resolveProjectPackageManager(root)
44
55
  execSync(`${packageManager} add ${packageDefaults.packageName}@${targetVersion}`, {
45
56
  cwd: root,
46
57
  stdio: 'inherit',