blun-king-cli 9.1.260 → 9.1.262

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.
@@ -116,6 +116,7 @@ function renderActor(lines, actor) {
116
116
  addField(lines, 'Kind', actor.kind);
117
117
  addField(lines, 'Role', actor.role);
118
118
  addList(lines, 'Confirmed aliases', actor.aliases);
119
+ addField(lines, 'First known interaction', trustedTimestamp(actor.first_seen_at));
119
120
  }
120
121
 
121
122
  function renderRelationship(lines, relationship) {
@@ -1,5 +1,18 @@
1
1
  'use strict';
2
2
 
3
+ const STABLE_VERSION_RE = /^(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)$/u;
4
+
5
+ function trustedVersion(value) {
6
+ const version = typeof value === 'string' ? value.trim() : '';
7
+ return STABLE_VERSION_RE.test(version) ? version : undefined;
8
+ }
9
+
10
+ function resolveTelegramRemoteVersion(input = {}) {
11
+ return trustedVersion(input.activeRuntimeVersion)
12
+ || trustedVersion(input.bridgePackageVersion)
13
+ || 'unbekannt';
14
+ }
15
+
3
16
  function formatDuration(seconds) {
4
17
  const minutes = Math.max(0, Math.floor(Number(seconds) / 60));
5
18
  if (minutes < 60) return `${minutes} min`;
@@ -38,4 +51,9 @@ function buildTelegramRemoteStatus(input) {
38
51
  ].join('\n');
39
52
  }
40
53
 
41
- module.exports = { buildTelegramRemoteStatus, formatBytes, formatDuration };
54
+ module.exports = {
55
+ buildTelegramRemoteStatus,
56
+ formatBytes,
57
+ formatDuration,
58
+ resolveTelegramRemoteVersion,
59
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "blun-king-cli",
3
- "version": "9.1.260",
3
+ "version": "9.1.262",
4
4
  "description": "BLUN CLI - your own AI agent with a Telegram channel. Get it done. With BLUN.",
5
5
  "license": "MIT",
6
6
  "bin": {
@@ -7,7 +7,7 @@ import { Readable, Writable } from "node:stream";
7
7
  import { fileURLToPath } from "node:url";
8
8
  import { hostname } from "node:os";
9
9
  import remoteStatusPolicy from "../../bin/telegram-remote-status-policy.cjs";
10
- const { buildTelegramRemoteStatus } = remoteStatusPolicy;
10
+ const { buildTelegramRemoteStatus, resolveTelegramRemoteVersion } = remoteStatusPolicy;
11
11
  //#region ../../node_modules/pathe/dist/shared/pathe.M-eThtNZ.mjs
12
12
  const _DRIVE_LETTER_START_RE = /^[A-Za-z]:\//;
13
13
  function normalizeWindowsPath(input = "") {
@@ -4699,7 +4699,10 @@ bot.command("status", async (ctx) => {
4699
4699
  tuiFresh: isTuiLeaseFresh(),
4700
4700
  tuiPid: Number.isInteger(tuiPid) ? tuiPid : void 0,
4701
4701
  username: ctx.from?.username,
4702
- version
4702
+ version: resolveTelegramRemoteVersion({
4703
+ activeRuntimeVersion: process.env.BLUN_PUBLIC_PACKAGE_VERSION,
4704
+ bridgePackageVersion: version
4705
+ })
4703
4706
  }));
4704
4707
  return;
4705
4708
  }