@just-every/manager 0.1.5 → 0.1.6
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/bin/justevery-manager.js +2 -3
- package/lib/installer.js +2 -3
- package/package.json +1 -1
package/bin/justevery-manager.js
CHANGED
|
@@ -6,10 +6,9 @@ const args = process.argv.slice(2);
|
|
|
6
6
|
const wantsHelp = args.includes('--help') || args.includes('-h');
|
|
7
7
|
const skipLaunchEnv = process.env.JE_AGENT_SKIP_LAUNCH === '1' || process.env.JE_MANAGER_SKIP_LAUNCH === '1';
|
|
8
8
|
const sessionType = (process.env.XDG_SESSION_TYPE || '').toLowerCase();
|
|
9
|
-
const isSsh = Boolean(process.env.SSH_CONNECTION || process.env.SSH_TTY || process.env.SSH_CLIENT);
|
|
10
9
|
const hasDisplay = Boolean(process.env.DISPLAY || process.env.WAYLAND_DISPLAY);
|
|
11
|
-
const hasGuiSession = Boolean(sessionType) && sessionType !== 'tty';
|
|
12
|
-
const isHeadlessLinux = osPlatform() === 'linux' &&
|
|
10
|
+
const hasGuiSession = hasDisplay || (Boolean(sessionType) && sessionType !== 'tty');
|
|
11
|
+
const isHeadlessLinux = osPlatform() === 'linux' && !hasGuiSession;
|
|
13
12
|
const downloadOnly = args.includes('--download-only') || args.includes('--no-open') || skipLaunchEnv || isHeadlessLinux;
|
|
14
13
|
const printPath = args.includes('--print-path');
|
|
15
14
|
|
package/lib/installer.js
CHANGED
|
@@ -323,9 +323,8 @@ function shouldSkipLaunch() {
|
|
|
323
323
|
if (osPlatform() !== 'linux') return false;
|
|
324
324
|
const hasDisplay = Boolean(process.env.DISPLAY || process.env.WAYLAND_DISPLAY);
|
|
325
325
|
const sessionType = (process.env.XDG_SESSION_TYPE || '').toLowerCase();
|
|
326
|
-
const hasGuiSession = Boolean(sessionType) && sessionType !== 'tty';
|
|
327
|
-
|
|
328
|
-
return !hasDisplay || !hasGuiSession || isSsh;
|
|
326
|
+
const hasGuiSession = hasDisplay || (Boolean(sessionType) && sessionType !== 'tty');
|
|
327
|
+
return !hasGuiSession;
|
|
329
328
|
}
|
|
330
329
|
|
|
331
330
|
export async function resolveAgentVersion() {
|