@livedesk/client 0.1.16 → 0.1.18

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
@@ -34,8 +34,9 @@ playback. When file transfer is enabled by the manager, received files are saved
34
34
  to `Desktop/LiveDeskFiles` unless the manager sets another destination folder.
35
35
 
36
36
  By default, the launcher uses the packaged C# RemoteFast engine when supported.
37
- It falls back to the Node engine for AI assist or when a compatible .NET runtime
38
- is unavailable.
37
+ It falls back to the Node engine for AI assist or when a compatible RemoteFast
38
+ runtime is unavailable. Linux currently uses the Node engine with native
39
+ `node-screenshots` capture for thumbnails and live frames.
39
40
 
40
41
  Useful flags:
41
42
 
@@ -6,7 +6,7 @@ import path from 'path';
6
6
  import crypto from 'crypto';
7
7
  import { promises as fs, statfsSync } from 'fs';
8
8
 
9
- const AGENT_VERSION = '0.1.16-livedesk.1';
9
+ const AGENT_VERSION = '0.1.17-livedesk.1';
10
10
  const DEFAULT_MANAGER = '127.0.0.1:5197';
11
11
  const DEFAULT_HEARTBEAT_MS = 5000;
12
12
  const DEFAULT_AI_MODEL = 'gpt-5.4-mini';
@@ -58,8 +58,20 @@ function isFalsy(value) {
58
58
  return /^(0|false|no|off)$/i.test(String(value || '').trim());
59
59
  }
60
60
 
61
+ function isNativeDesktopCaptureEnabledByDefault() {
62
+ const platform = os.platform();
63
+ const arch = os.arch();
64
+ if (platform === 'win32' || platform === 'darwin') {
65
+ return true;
66
+ }
67
+ if (platform === 'linux') {
68
+ return ['x64', 'arm64', 'loong64'].includes(arch);
69
+ }
70
+ return false;
71
+ }
72
+
61
73
  function parseArgs(argv) {
62
- const defaultDesktopCaptureEnabled = os.platform() === 'win32';
74
+ const defaultDesktopCaptureEnabled = isNativeDesktopCaptureEnabledByDefault();
63
75
  const result = {
64
76
  command: 'connect',
65
77
  manager: process.env.LIVEDESK_CLIENT_MANAGER || process.env.MINDEXEC_REMOTE_MANAGER || DEFAULT_MANAGER,
@@ -62,6 +62,15 @@ when a packaged RemoteFast runtime is unavailable.
62
62
  `.trimStart());
63
63
  }
64
64
 
65
+ function readPackageVersion() {
66
+ try {
67
+ const packageInfo = JSON.parse(readFileSync(join(packageRoot, 'package.json'), 'utf8'));
68
+ return packageInfo.version || '0.0.0';
69
+ } catch {
70
+ return '0.0.0';
71
+ }
72
+ }
73
+
65
74
  function normalizeEngine(value) {
66
75
  const engine = String(value || 'auto').trim().toLowerCase();
67
76
  if (engine === 'c#' || engine === 'csharp' || engine === 'fast') {
@@ -806,16 +815,27 @@ function shouldUseFast(parsed) {
806
815
  return !parsed.nodeOnlyFeature;
807
816
  }
808
817
 
818
+ function shouldTryFast(parsed, runtime) {
819
+ if (parsed.engine === 'fast') {
820
+ return true;
821
+ }
822
+ return shouldUseFast(parsed) && !!runtime;
823
+ }
824
+
809
825
  async function main() {
810
826
  const parsed = parseLauncherArgs(process.argv.slice(2));
811
827
  if (parsed.help) {
812
828
  printHelp();
813
829
  return;
814
830
  }
831
+ if (parsed.version) {
832
+ console.log(readPackageVersion());
833
+ return;
834
+ }
815
835
 
816
836
  const prepared = await prepareLoginConnection(parsed);
817
837
  const fastRuntime = getFastRuntime();
818
- const useFast = shouldUseFast(prepared);
838
+ const useFast = shouldTryFast(prepared, fastRuntime);
819
839
  if (useFast) {
820
840
  const fastArgs = buildFastArgs(prepared.forwarded, prepared.fakeThumbnail);
821
841
  const fastLaunch = resolveFastLaunch(fastRuntime);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@livedesk/client",
3
- "version": "0.1.16",
3
+ "version": "0.1.18",
4
4
  "description": "LiveDesk local remote client",
5
5
  "type": "module",
6
6
  "bin": {