From 2ee43e010b708bdef5c9094df3d0981ffa51159a Mon Sep 17 00:00:00 2001 From: SenaxZz Date: Wed, 1 Apr 2026 13:53:36 +0200 Subject: [PATCH] Fix Windows ESM import by using file URL --- bin/openclaude | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/bin/openclaude b/bin/openclaude index a5688523..2ecc153f 100755 --- a/bin/openclaude +++ b/bin/openclaude @@ -9,14 +9,13 @@ import { existsSync } from 'fs' import { join, dirname } from 'path' -import { fileURLToPath } from 'url' -import { getDistImportSpecifier } from './import-specifier.mjs' +import { fileURLToPath, pathToFileURL } from 'url' const __dirname = dirname(fileURLToPath(import.meta.url)) const distPath = join(__dirname, '..', 'dist', 'cli.mjs') if (existsSync(distPath)) { - await import(getDistImportSpecifier(__dirname)) + await import(pathToFileURL(distPath).href) } else { console.error(` openclaude: dist/cli.mjs not found.