Files
pbakaus_impeccable/skill/scripts/impeccable.cmd
T
Paul Bakaus dac3f77d89 Scripts dir: replace the Node scripts with the impeccable launcher
skill/scripts keeps command-metadata.json and the page JS; every .mjs entry
point, lib/, and live/ are gone (the binary owns those verbs). Adds the POSIX
launcher, impeccable.cmd, VERSION (copied from the new root ENGINE_VERSION),
scripts/fetch-engine.mjs (bun run fetch:engine) to pull the pinned binary
into skill/scripts/bin/<os>-<arch>/, and gitignores that bin dir.

Prepared with AI assistance (Claude Code).
2026-08-31 19:57:32 -07:00

45 lines
1.7 KiB
Batchfile

@echo off
setlocal
rem Impeccable launcher (Windows). Runs bin\windows-x64\impeccable.exe next to this file.
if defined IMPECCABLE_BIN if exist "%IMPECCABLE_BIN%" (
"%IMPECCABLE_BIN%" %*
exit /b %ERRORLEVEL%
)
if not defined IMPECCABLE_SKILL_DIR set "IMPECCABLE_SKILL_DIR=%~dp0.."
if not defined IMPECCABLE_SELF set "IMPECCABLE_SELF=%~f0"
set "arch=x64"
if /I "%PROCESSOR_ARCHITECTURE%"=="ARM64" set "arch=arm64"
set "bin=%~dp0bin\windows-%arch%\impeccable.exe"
if exist "%bin%" (
"%bin%" %*
exit /b %ERRORLEVEL%
)
if exist "%USERPROFILE%\.impeccable\bin\impeccable.exe" (
"%USERPROFILE%\.impeccable\bin\impeccable.exe" %*
exit /b %ERRORLEVEL%
)
set "version="
if exist "%~dp0VERSION" set /p version=<"%~dp0VERSION"
if not defined IMPECCABLE_HOME set "IMPECCABLE_HOME=%USERPROFILE%\.impeccable"
set "cached=%IMPECCABLE_HOME%\bin\%version%\impeccable.exe"
if defined version if exist "%cached%" (
"%cached%" %*
exit /b %ERRORLEVEL%
)
where impeccable >nul 2>nul && (
impeccable %*
exit /b %ERRORLEVEL%
)
if defined version (
if not defined IMPECCABLE_DOWNLOAD_BASE set "IMPECCABLE_DOWNLOAD_BASE=https://github.com/renaissance-geek-inc/impeccable-dist/releases/download"
set "url=%IMPECCABLE_DOWNLOAD_BASE%/v%version%/impeccable-windows-%arch%.exe"
if not exist "%IMPECCABLE_HOME%\bin\%version%" mkdir "%IMPECCABLE_HOME%\bin\%version%" >nul 2>nul
where curl.exe >nul 2>nul && curl.exe -fsSL -o "%cached%.part" "%url%" >nul 2>nul && move /y "%cached%.part" "%cached%" >nul 2>nul
if exist "%cached%" (
"%cached%" %*
exit /b %ERRORLEVEL%
)
)
echo impeccable: no binary found (looked in %bin%, %cached%, PATH). Install one: npm i -g impeccable 1>&2
exit /b 127