@google/gemini-cli 0.40.0-preview.4 → 0.40.0

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.
Files changed (60) hide show
  1. package/bundle/{chunk-4XVBQQNJ.js → chunk-3F3SMPJP.js} +6 -6
  2. package/bundle/{chunk-KG7ZFMJL.js → chunk-3OSQ5US4.js} +12 -12
  3. package/bundle/{chunk-PRZIW6SM.js → chunk-BSQN7W2F.js} +1 -1
  4. package/bundle/{chunk-M76FWZ5L.js → chunk-DYY5TRG5.js} +1 -1
  5. package/bundle/{chunk-63PTTRTA.js → chunk-EITHKKXC.js} +2 -2
  6. package/bundle/{chunk-NV6UCR4K.js → chunk-FRSESBS3.js} +11912 -6390
  7. package/bundle/{chunk-G356GKHH.js → chunk-G6ODSHKI.js} +1 -1
  8. package/bundle/{chunk-HGFADN5A.js → chunk-HMR2JSPA.js} +1 -1
  9. package/bundle/{chunk-H7F2VOIJ.js → chunk-J76QO4KN.js} +6 -6
  10. package/bundle/{chunk-CJQVVQSH.js → chunk-MBLCGSJW.js} +1 -1
  11. package/bundle/{chunk-SYPUOR3U.js → chunk-ML7VG4QG.js} +2 -2
  12. package/bundle/{chunk-WSTHO4WR.js → chunk-O7SPQTAS.js} +2 -2
  13. package/bundle/{chunk-H4NQBTXN.js → chunk-OE2ZUR66.js} +12 -14
  14. package/bundle/{chunk-547AWTTH.js → chunk-OEIRJHU4.js} +54 -67
  15. package/bundle/{chunk-VQ7N6NVX.js → chunk-P7LA6IIC.js} +1 -1
  16. package/bundle/{chunk-ZQNX6OWU.js → chunk-RUHTTGS7.js} +3 -3
  17. package/bundle/{chunk-CIO3GUGQ.js → chunk-SZYCJREE.js} +12 -12
  18. package/bundle/{chunk-BV2W6YE6.js → chunk-URTDU3HF.js} +1 -1
  19. package/bundle/{cleanup-DNS7PXYC.js → cleanup-6MKBWA6V.js} +2 -2
  20. package/bundle/{cleanup-4EFDM2N7.js → cleanup-AJ7G3WEE.js} +2 -2
  21. package/bundle/{cleanup-4RRVO4GO.js → cleanup-SOJQVOTG.js} +3 -3
  22. package/bundle/{core-WQSFCPEO.js → core-KELRGMHQ.js} +1 -1
  23. package/bundle/{dist-RIVCP5ZD.js → core-O5TD6NYP.js} +2 -2
  24. package/bundle/{devtoolsService-JWET4G6G.js → devtoolsService-AR5HWQA7.js} +2 -2
  25. package/bundle/{devtoolsService-LPEBYJVD.js → devtoolsService-CCXHJEUM.js} +2 -2
  26. package/bundle/{devtoolsService-S2LBUUZU.js → devtoolsService-GQF7V6FB.js} +4 -5
  27. package/bundle/{dist-ANTOB3YW.js → dist-LZ5ASNAL.js} +1 -1
  28. package/bundle/docs/reference/configuration.md +7 -7
  29. package/bundle/{gemini-57EC2ZF7.js → gemini-LSLMD4HG.js} +12 -12
  30. package/bundle/{gemini-27FQ5BI4.js → gemini-TKPXJBGX.js} +175 -191
  31. package/bundle/{gemini-JAZVYRDD.js → gemini-YJTI2WQP.js} +12 -12
  32. package/bundle/gemini.js +3 -3
  33. package/bundle/{interactiveCli-E35R6QQC.js → interactiveCli-5YSP2IQI.js} +6 -6
  34. package/bundle/{interactiveCli-L3EK4XEX.js → interactiveCli-I56L63GE.js} +272 -290
  35. package/bundle/{interactiveCli-FPHSBRV3.js → interactiveCli-O3UYJUNT.js} +6 -6
  36. package/bundle/{liteRtServerManager-ORSW3R4F.js → liteRtServerManager-6INPACOA.js} +3 -3
  37. package/bundle/{liteRtServerManager-LXEAYAUP.js → liteRtServerManager-CIC7DD4U.js} +3 -3
  38. package/bundle/{liteRtServerManager-YYXO5Q3I.js → liteRtServerManager-XI56E5P3.js} +4 -4
  39. package/bundle/node_modules/@google/gemini-cli-devtools/package.json +1 -1
  40. package/bundle/{oauth2-provider-I3G773GE.js → oauth2-provider-HDKVDC2Q.js} +1 -1
  41. package/bundle/{oauth2-provider-B3NTBNAM.js → oauth2-provider-HUMYTY6K.js} +1 -1
  42. package/bundle/{oauth2-provider-ENF2D4Q7.js → oauth2-provider-VGGNG5XI.js} +73 -39
  43. package/bundle/{start-CRIFZ3SW.js → start-25VD33TV.js} +5 -5
  44. package/bundle/{start-S3REI3X2.js → start-U4YQCY2A.js} +6 -6
  45. package/bundle/{start-KVFKS3IT.js → start-VHURPYN7.js} +5 -5
  46. package/package.json +1 -1
  47. package/bundle/chunk-ATGIEBEB.js +0 -1571
  48. package/bundle/chunk-HF7X35D3.js +0 -80012
  49. package/bundle/chunk-LMVZLINC.js +0 -118
  50. package/bundle/chunk-LODNDE3S.js +0 -17505
  51. package/bundle/chunk-LVHUYMBU.js +0 -156
  52. package/bundle/chunk-RENFZ63F.js +0 -351149
  53. package/bundle/cleanup-DXHNV2J6.js +0 -33
  54. package/bundle/devtoolsService-YCRNWWXE.js +0 -852
  55. package/bundle/dist-UH565MTG.js +0 -2046
  56. package/bundle/gemini-TQZRS37Q.js +0 -16087
  57. package/bundle/interactiveCli-MVHR4VV7.js +0 -34448
  58. package/bundle/liteRtServerManager-PI4ZNFB5.js +0 -65
  59. package/bundle/oauth2-provider-WTF7AHQ2.js +0 -237
  60. package/bundle/start-OTLGMCNH.js +0 -18
@@ -1,118 +0,0 @@
1
- const require = (await import('node:module')).createRequire(import.meta.url); const __chunk_filename = (await import('node:url')).fileURLToPath(import.meta.url); const __chunk_dirname = (await import('node:path')).dirname(__chunk_filename);
2
- import {
3
- exitCli,
4
- require_source
5
- } from "./chunk-G356GKHH.js";
6
- import {
7
- DEFAULT_PORT,
8
- SERVER_START_WAIT_MS,
9
- getBinaryPath,
10
- getLiteRtBinDir,
11
- getLogFilePath,
12
- getPidFilePath,
13
- isBinaryInstalled,
14
- isServerRunning,
15
- resolveGemmaConfig,
16
- writeServerProcessInfo
17
- } from "./chunk-CJQVVQSH.js";
18
- import {
19
- debugLogger
20
- } from "./chunk-F73F75XM.js";
21
- import {
22
- __toESM
23
- } from "./chunk-34MYV7JD.js";
24
-
25
- // packages/cli/src/commands/gemma/start.ts
26
- var import_chalk = __toESM(require_source(), 1);
27
- import fs from "node:fs";
28
- import path from "node:path";
29
- import { spawn } from "node:child_process";
30
- async function startServer(binaryPath, port) {
31
- const alreadyRunning = await isServerRunning(port);
32
- if (alreadyRunning) {
33
- debugLogger.log(`LiteRT server already running on port ${port}`);
34
- return true;
35
- }
36
- const logPath = getLogFilePath();
37
- fs.mkdirSync(getLiteRtBinDir(), { recursive: true });
38
- const tmpDir = path.dirname(getPidFilePath());
39
- fs.mkdirSync(tmpDir, { recursive: true });
40
- const logFd = fs.openSync(logPath, "a");
41
- try {
42
- const child = spawn(binaryPath, ["serve", `--port=${port}`, "--verbose"], {
43
- detached: true,
44
- stdio: ["ignore", logFd, logFd]
45
- });
46
- if (child.pid) {
47
- writeServerProcessInfo({
48
- pid: child.pid,
49
- binaryPath,
50
- port
51
- });
52
- }
53
- child.unref();
54
- } finally {
55
- fs.closeSync(logFd);
56
- }
57
- await new Promise((resolve) => setTimeout(resolve, SERVER_START_WAIT_MS));
58
- return isServerRunning(port);
59
- }
60
- var startCommand = {
61
- command: "start",
62
- describe: "Start the LiteRT-LM server",
63
- builder: (yargs) => yargs.option("port", {
64
- type: "number",
65
- description: "Port for the LiteRT server"
66
- }),
67
- handler: async (argv) => {
68
- let port;
69
- if (argv["port"] !== void 0) {
70
- port = Number(argv["port"]);
71
- }
72
- if (!port) {
73
- const { configuredPort } = resolveGemmaConfig(DEFAULT_PORT);
74
- port = configuredPort;
75
- }
76
- const binaryPath = getBinaryPath();
77
- if (!binaryPath || !isBinaryInstalled(binaryPath)) {
78
- debugLogger.error(
79
- import_chalk.default.red(
80
- 'LiteRT-LM binary not found. Run "gemini gemma setup" first.'
81
- )
82
- );
83
- await exitCli(1);
84
- return;
85
- }
86
- const alreadyRunning = await isServerRunning(port);
87
- if (alreadyRunning) {
88
- debugLogger.log(
89
- import_chalk.default.green(`LiteRT server is already running on port ${port}.`)
90
- );
91
- await exitCli(0);
92
- return;
93
- }
94
- debugLogger.log(`Starting LiteRT server on port ${port}...`);
95
- const started = await startServer(binaryPath, port);
96
- if (started) {
97
- debugLogger.log(import_chalk.default.green(`LiteRT server started on port ${port}.`));
98
- debugLogger.log(import_chalk.default.dim(`Logs: ${getLogFilePath()}`));
99
- await exitCli(0);
100
- } else {
101
- debugLogger.error(
102
- import_chalk.default.red("Server may not have started correctly. Check logs:")
103
- );
104
- debugLogger.error(import_chalk.default.dim(` ${getLogFilePath()}`));
105
- await exitCli(1);
106
- }
107
- }
108
- };
109
-
110
- export {
111
- startServer,
112
- startCommand
113
- };
114
- /**
115
- * @license
116
- * Copyright 2026 Google LLC
117
- * SPDX-License-Identifier: Apache-2.0
118
- */