merge: PR #275 - fix: support Linux Chromium cookie import

Conflict resolution: combined #65's multi-profile scanning with
#275's platform-aware path resolution. listProfiles() and
findInstalledBrowsers() now work across macOS and Linux.
This commit is contained in:
Garry Tan
2026-03-22 22:52:36 -07:00
8 changed files with 386 additions and 123 deletions

View File

@@ -6,7 +6,7 @@
*/
import type { BrowserManager } from './browser-manager';
import { findInstalledBrowsers, importCookies } from './cookie-import-browser';
import { findInstalledBrowsers, importCookies, listSupportedBrowserNames } from './cookie-import-browser';
import { validateNavigationUrl } from './url-validation';
import * as fs from 'fs';
import * as path from 'path';
@@ -335,7 +335,7 @@ export async function handleWriteCommand(
const browsers = findInstalledBrowsers();
if (browsers.length === 0) {
throw new Error('No Chromium browsers found. Supported: Comet, Chrome, Arc, Brave, Edge');
throw new Error(`No Chromium browsers found. Supported: ${listSupportedBrowserNames().join(', ')}`);
}
const pickerUrl = `http://127.0.0.1:${port}/cookie-picker`;