genbox 1.0.242 → 1.0.244

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.
@@ -1,7 +1,8 @@
1
1
  /**
2
2
  * Theme Utilities
3
3
  *
4
- * Provides automatic theme detection based on time of day.
4
+ * Provides automatic theme detection based on system preferences.
5
+ * Falls back to time-based detection if system theme cannot be detected.
5
6
  * Used by session commands to set light/dark theme for AI CLIs.
6
7
  *
7
8
  * Claude Code CLI: Theme is configured via ~/.claude/settings.json
@@ -9,12 +10,20 @@
9
10
  * - No command-line flag available (removed in v2.0.0)
10
11
  *
11
12
  * Gemini CLI: Theme is configured via ~/.gemini/settings.json
12
- * - Format: { "ui": { "theme": "dark" } }
13
+ * - Format: { "theme": "Default Light" } or { "theme": "Default Dark" }
13
14
  * - No command-line flag available
14
15
  */
15
16
  export type Theme = 'light' | 'dark';
17
+ /**
18
+ * Detect the system theme based on the current platform.
19
+ * Returns null if detection fails or platform is unsupported.
20
+ *
21
+ * @returns 'dark' or 'light' based on system preference, null if detection fails
22
+ */
23
+ export declare function detectSystemTheme(): Theme | null;
16
24
  /**
17
25
  * Get the appropriate theme based on the current time of day.
26
+ * This is used as a fallback when system theme detection fails.
18
27
  *
19
28
  * @param options Optional configuration for day/night hours
20
29
  * @returns 'light' during day hours (6 AM - 6 PM), 'dark' otherwise
@@ -25,27 +34,36 @@ export declare function getThemeForTime(options?: {
25
34
  now?: Date;
26
35
  }): Theme;
27
36
  /**
28
- * Get the theme for Claude CLI based on current time.
37
+ * Get the current theme, preferring system detection over time-based.
38
+ *
39
+ * @returns The detected system theme, or time-based fallback
40
+ */
41
+ export declare function getSystemTheme(): Theme;
42
+ /**
43
+ * Get the theme for Claude CLI based on system preference.
44
+ * Falls back to time-based detection if system theme cannot be detected.
29
45
  *
30
46
  * @returns The theme value
31
47
  */
32
48
  export declare function getClaudeTheme(): Theme;
33
49
  /**
34
- * Get the theme for Gemini CLI based on current time.
50
+ * Get the theme for Gemini CLI based on system preference.
51
+ * Falls back to time-based detection if system theme cannot be detected.
35
52
  *
36
53
  * @returns The theme value (light/dark)
37
54
  */
38
55
  export declare function getGeminiTheme(): Theme;
39
56
  /**
40
- * Get the full Gemini theme name based on current time.
57
+ * Get the full Gemini theme name based on system preference.
41
58
  * Gemini CLI uses specific theme names like "Default Light", "Default Dark", etc.
59
+ * Falls back to time-based detection if system theme cannot be detected.
42
60
  *
43
61
  * @returns The full Gemini theme name
44
62
  */
45
63
  export declare function getGeminiThemeName(): string;
46
64
  /**
47
- * Update local Claude Code settings.json with the current time-based theme.
48
- * Creates the settings file if it doesn't exist.
65
+ * Update local Claude Code ~/.claude.json with the current system theme.
66
+ * Creates the config file if it doesn't exist.
49
67
  *
50
68
  * @returns true if successfully updated, false otherwise
51
69
  */
@@ -54,7 +72,7 @@ export declare function updateClaudeTheme(): boolean;
54
72
  * Build a shell command to update Claude Code theme on a remote genbox.
55
73
  * This command can be run via SSH before starting a Claude session.
56
74
  *
57
- * @returns Shell command string to update Claude settings
75
+ * @returns Shell command string to update Claude config
58
76
  */
59
77
  export declare function buildRemoteClaudeThemeCommand(): string;
60
78
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"theme-utils.d.ts","sourceRoot":"","sources":["../../src/utils/theme-utils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAMH,MAAM,MAAM,KAAK,GAAG,OAAO,GAAG,MAAM,CAAC;AAQrC;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,OAAO,CAAC,EAAE;IACxC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,GAAG,CAAC,EAAE,IAAI,CAAC;CACZ,GAAG,KAAK,CAgBR;AAED;;;;GAIG;AACH,wBAAgB,cAAc,IAAI,KAAK,CAEtC;AAED;;;;GAIG;AACH,wBAAgB,cAAc,IAAI,KAAK,CAEtC;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,IAAI,MAAM,CAI3C;AASD;;;;;GAKG;AACH,wBAAgB,iBAAiB,IAAI,OAAO,CAiC3C;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,IAAI,MAAM,CAiBtD;AASD;;;;;GAKG;AACH,wBAAgB,iBAAiB,IAAI,OAAO,CAsC3C;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,IAAI,MAAM,CAkBtD"}
1
+ {"version":3,"file":"theme-utils.d.ts","sourceRoot":"","sources":["../../src/utils/theme-utils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAOH,MAAM,MAAM,KAAK,GAAG,OAAO,GAAG,MAAM,CAAC;AAqHrC;;;;;GAKG;AACH,wBAAgB,iBAAiB,IAAI,KAAK,GAAG,IAAI,CAahD;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,OAAO,CAAC,EAAE;IACxC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,GAAG,CAAC,EAAE,IAAI,CAAC;CACZ,GAAG,KAAK,CAgBR;AAED;;;;GAIG;AACH,wBAAgB,cAAc,IAAI,KAAK,CAOtC;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,IAAI,KAAK,CAEtC;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,IAAI,KAAK,CAEtC;AAED;;;;;;GAMG;AACH,wBAAgB,kBAAkB,IAAI,MAAM,CAI3C;AAYD;;;;;GAKG;AACH,wBAAgB,iBAAiB,IAAI,OAAO,CA2B3C;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,IAAI,MAAM,CAgBtD;AASD;;;;;GAKG;AACH,wBAAgB,iBAAiB,IAAI,OAAO,CAsC3C;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,IAAI,MAAM,CAkBtD"}
@@ -1,7 +1,8 @@
1
1
  /**
2
2
  * Theme Utilities
3
3
  *
4
- * Provides automatic theme detection based on time of day.
4
+ * Provides automatic theme detection based on system preferences.
5
+ * Falls back to time-based detection if system theme cannot be detected.
5
6
  * Used by session commands to set light/dark theme for AI CLIs.
6
7
  *
7
8
  * Claude Code CLI: Theme is configured via ~/.claude/settings.json
@@ -9,19 +10,143 @@
9
10
  * - No command-line flag available (removed in v2.0.0)
10
11
  *
11
12
  * Gemini CLI: Theme is configured via ~/.gemini/settings.json
12
- * - Format: { "ui": { "theme": "dark" } }
13
+ * - Format: { "theme": "Default Light" } or { "theme": "Default Dark" }
13
14
  * - No command-line flag available
14
15
  */
15
16
  import * as fs from 'fs';
16
17
  import * as path from 'path';
17
18
  import * as os from 'os';
19
+ import { execSync } from 'child_process';
18
20
  /**
19
21
  * Default day hours (6 AM to 6 PM is considered "day")
22
+ * Used as fallback when system theme detection fails.
20
23
  */
21
24
  const DEFAULT_DAY_START_HOUR = 6; // 6 AM
22
25
  const DEFAULT_DAY_END_HOUR = 18; // 6 PM
26
+ /**
27
+ * Detect the system theme on macOS.
28
+ * Uses `defaults read -g AppleInterfaceStyle` which returns "Dark" if dark mode is enabled.
29
+ *
30
+ * @returns 'dark' if dark mode, 'light' if light mode, null if detection fails
31
+ */
32
+ function detectMacOSTheme() {
33
+ try {
34
+ const result = execSync('defaults read -g AppleInterfaceStyle 2>/dev/null', {
35
+ encoding: 'utf-8',
36
+ timeout: 1000,
37
+ }).trim();
38
+ return result === 'Dark' ? 'dark' : 'light';
39
+ }
40
+ catch {
41
+ // Command fails or returns empty when in light mode
42
+ return 'light';
43
+ }
44
+ }
45
+ /**
46
+ * Detect the system theme on Linux.
47
+ * Tries multiple methods for different desktop environments:
48
+ * - GNOME/GTK: gsettings
49
+ * - KDE: kreadconfig5
50
+ * - Generic: GTK_THEME environment variable
51
+ *
52
+ * @returns 'dark' if dark mode, 'light' if light mode, null if detection fails
53
+ */
54
+ function detectLinuxTheme() {
55
+ // Try GNOME/GTK (most common)
56
+ try {
57
+ const result = execSync('gsettings get org.gnome.desktop.interface color-scheme 2>/dev/null', {
58
+ encoding: 'utf-8',
59
+ timeout: 1000,
60
+ }).trim();
61
+ if (result.includes('dark')) {
62
+ return 'dark';
63
+ }
64
+ if (result.includes('light') || result.includes('default')) {
65
+ return 'light';
66
+ }
67
+ }
68
+ catch {
69
+ // gsettings not available or failed
70
+ }
71
+ // Try GTK theme setting
72
+ try {
73
+ const result = execSync('gsettings get org.gnome.desktop.interface gtk-theme 2>/dev/null', {
74
+ encoding: 'utf-8',
75
+ timeout: 1000,
76
+ }).trim().toLowerCase();
77
+ if (result.includes('dark')) {
78
+ return 'dark';
79
+ }
80
+ }
81
+ catch {
82
+ // gsettings not available or failed
83
+ }
84
+ // Try KDE
85
+ try {
86
+ const result = execSync('kreadconfig5 --group General --key ColorScheme 2>/dev/null', {
87
+ encoding: 'utf-8',
88
+ timeout: 1000,
89
+ }).trim().toLowerCase();
90
+ if (result.includes('dark')) {
91
+ return 'dark';
92
+ }
93
+ if (result) {
94
+ return 'light';
95
+ }
96
+ }
97
+ catch {
98
+ // kreadconfig5 not available or failed
99
+ }
100
+ // Check GTK_THEME environment variable
101
+ const gtkTheme = process.env.GTK_THEME?.toLowerCase();
102
+ if (gtkTheme) {
103
+ return gtkTheme.includes('dark') ? 'dark' : 'light';
104
+ }
105
+ // Check for common dark theme indicators in environment
106
+ const colorScheme = process.env.COLOR_SCHEME?.toLowerCase();
107
+ if (colorScheme) {
108
+ return colorScheme.includes('dark') ? 'dark' : 'light';
109
+ }
110
+ return null;
111
+ }
112
+ /**
113
+ * Detect the system theme on Windows.
114
+ * Uses PowerShell to read the registry key for app theme preference.
115
+ *
116
+ * @returns 'dark' if dark mode, 'light' if light mode, null if detection fails
117
+ */
118
+ function detectWindowsTheme() {
119
+ try {
120
+ const result = execSync('powershell -NoProfile -Command "(Get-ItemProperty -Path HKCU:\\Software\\Microsoft\\Windows\\CurrentVersion\\Themes\\Personalize -Name AppsUseLightTheme).AppsUseLightTheme"', { encoding: 'utf-8', timeout: 2000 }).trim();
121
+ // 0 = dark mode, 1 = light mode
122
+ return result === '0' ? 'dark' : 'light';
123
+ }
124
+ catch {
125
+ return null;
126
+ }
127
+ }
128
+ /**
129
+ * Detect the system theme based on the current platform.
130
+ * Returns null if detection fails or platform is unsupported.
131
+ *
132
+ * @returns 'dark' or 'light' based on system preference, null if detection fails
133
+ */
134
+ export function detectSystemTheme() {
135
+ const platform = os.platform();
136
+ switch (platform) {
137
+ case 'darwin':
138
+ return detectMacOSTheme();
139
+ case 'linux':
140
+ return detectLinuxTheme();
141
+ case 'win32':
142
+ return detectWindowsTheme();
143
+ default:
144
+ return null;
145
+ }
146
+ }
23
147
  /**
24
148
  * Get the appropriate theme based on the current time of day.
149
+ * This is used as a fallback when system theme detection fails.
25
150
  *
26
151
  * @param options Optional configuration for day/night hours
27
152
  * @returns 'light' during day hours (6 AM - 6 PM), 'dark' otherwise
@@ -37,69 +162,83 @@ export function getThemeForTime(options) {
37
162
  return 'dark';
38
163
  }
39
164
  /**
40
- * Get the theme for Claude CLI based on current time.
165
+ * Get the current theme, preferring system detection over time-based.
166
+ *
167
+ * @returns The detected system theme, or time-based fallback
168
+ */
169
+ export function getSystemTheme() {
170
+ const systemTheme = detectSystemTheme();
171
+ if (systemTheme !== null) {
172
+ return systemTheme;
173
+ }
174
+ // Fall back to time-based detection
175
+ return getThemeForTime();
176
+ }
177
+ /**
178
+ * Get the theme for Claude CLI based on system preference.
179
+ * Falls back to time-based detection if system theme cannot be detected.
41
180
  *
42
181
  * @returns The theme value
43
182
  */
44
183
  export function getClaudeTheme() {
45
- return getThemeForTime();
184
+ return getSystemTheme();
46
185
  }
47
186
  /**
48
- * Get the theme for Gemini CLI based on current time.
187
+ * Get the theme for Gemini CLI based on system preference.
188
+ * Falls back to time-based detection if system theme cannot be detected.
49
189
  *
50
190
  * @returns The theme value (light/dark)
51
191
  */
52
192
  export function getGeminiTheme() {
53
- return getThemeForTime();
193
+ return getSystemTheme();
54
194
  }
55
195
  /**
56
- * Get the full Gemini theme name based on current time.
196
+ * Get the full Gemini theme name based on system preference.
57
197
  * Gemini CLI uses specific theme names like "Default Light", "Default Dark", etc.
198
+ * Falls back to time-based detection if system theme cannot be detected.
58
199
  *
59
200
  * @returns The full Gemini theme name
60
201
  */
61
202
  export function getGeminiThemeName() {
62
- const theme = getThemeForTime();
203
+ const theme = getSystemTheme();
63
204
  // Use "Default Light" or "Default Dark" which match most terminal backgrounds
64
205
  return theme === 'light' ? 'Default Light' : 'Default Dark';
65
206
  }
66
207
  /**
67
- * Path to Claude Code settings.json
208
+ * Path to Claude Code config file (~/.claude.json)
209
+ * Note: Theme goes in ~/.claude.json (the preferences/state file),
210
+ * NOT in ~/.claude/settings.json (which is for other settings).
211
+ * See: https://github.com/anthropics/claude-code/issues/6962
68
212
  */
69
- function getClaudeSettingsPath() {
70
- return path.join(os.homedir(), '.claude', 'settings.json');
213
+ function getClaudeConfigPath() {
214
+ return path.join(os.homedir(), '.claude.json');
71
215
  }
72
216
  /**
73
- * Update local Claude Code settings.json with the current time-based theme.
74
- * Creates the settings file if it doesn't exist.
217
+ * Update local Claude Code ~/.claude.json with the current system theme.
218
+ * Creates the config file if it doesn't exist.
75
219
  *
76
220
  * @returns true if successfully updated, false otherwise
77
221
  */
78
222
  export function updateClaudeTheme() {
79
223
  const theme = getClaudeTheme();
80
- const settingsPath = getClaudeSettingsPath();
81
- const claudeDir = path.dirname(settingsPath);
224
+ const configPath = getClaudeConfigPath();
82
225
  try {
83
- // Ensure ~/.claude directory exists
84
- if (!fs.existsSync(claudeDir)) {
85
- fs.mkdirSync(claudeDir, { recursive: true });
86
- }
87
- // Read existing settings or create new
88
- let settings = {};
89
- if (fs.existsSync(settingsPath)) {
226
+ // Read existing config or create new
227
+ let config = {};
228
+ if (fs.existsSync(configPath)) {
90
229
  try {
91
- const content = fs.readFileSync(settingsPath, 'utf-8');
92
- settings = JSON.parse(content);
230
+ const content = fs.readFileSync(configPath, 'utf-8');
231
+ config = JSON.parse(content);
93
232
  }
94
233
  catch {
95
234
  // If file is corrupted, start fresh
96
- settings = {};
235
+ config = {};
97
236
  }
98
237
  }
99
238
  // Update the theme at root level
100
- settings.theme = theme;
239
+ config.theme = theme;
101
240
  // Write back
102
- fs.writeFileSync(settingsPath, JSON.stringify(settings, null, 2));
241
+ fs.writeFileSync(configPath, JSON.stringify(config, null, 2));
103
242
  return true;
104
243
  }
105
244
  catch {
@@ -111,22 +250,21 @@ export function updateClaudeTheme() {
111
250
  * Build a shell command to update Claude Code theme on a remote genbox.
112
251
  * This command can be run via SSH before starting a Claude session.
113
252
  *
114
- * @returns Shell command string to update Claude settings
253
+ * @returns Shell command string to update Claude config
115
254
  */
116
255
  export function buildRemoteClaudeThemeCommand() {
117
256
  const theme = getClaudeTheme();
118
257
  // This script:
119
- // 1. Creates ~/.claude if needed
120
- // 2. Reads existing settings.json or creates new
121
- // 3. Updates the theme value at root level
122
- // 4. Writes back the settings
258
+ // 1. Reads existing ~/.claude.json or creates new
259
+ // 2. Updates the theme value at root level
260
+ // 3. Writes back the config
261
+ // Note: Theme goes in ~/.claude.json, not ~/.claude/settings.json
123
262
  return `
124
- mkdir -p ~/.claude && \
125
- if [ -f ~/.claude/settings.json ]; then \
126
- node -e "const fs=require('fs'); const s=JSON.parse(fs.readFileSync('$HOME/.claude/settings.json','utf-8')||'{}'); s.theme='${theme}'; fs.writeFileSync('$HOME/.claude/settings.json',JSON.stringify(s,null,2));" 2>/dev/null || \
127
- echo '{"theme":"${theme}"}' > ~/.claude/settings.json; \
263
+ if [ -f ~/.claude.json ]; then \
264
+ node -e "const fs=require('fs'); const s=JSON.parse(fs.readFileSync('$HOME/.claude.json','utf-8')||'{}'); s.theme='${theme}'; fs.writeFileSync('$HOME/.claude.json',JSON.stringify(s,null,2));" 2>/dev/null || \
265
+ echo '{"theme":"${theme}"}' > ~/.claude.json; \
128
266
  else \
129
- echo '{"theme":"${theme}"}' > ~/.claude/settings.json; \
267
+ echo '{"theme":"${theme}"}' > ~/.claude.json; \
130
268
  fi
131
269
  `.trim().replace(/\n/g, ' ');
132
270
  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M,CAAC;QACP,0CAA0C;QAC1C,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,6BAA6B;IAC3C,MAAM,SAAS,GAAG,kBAAkB,EAAE,CAAC;IAEvC,eAAe;IACf,iCAAiC;IACjC,iDAAiD;IACjD,+FAA+F;IAC/F,8CAA8C;IAC9C,8BAA8B;IAC9B,OAAO;;;gIAGuH,SAAS;oBACrH,SAAS;;oBAET,SAAS;;CAE5B,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;AAC7B,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "genbox",
3
- "version": "1.0.242",
3
+ "version": "1.0.244",
4
4
  "description": "Genbox CLI - AI-Powered Development Environments",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",