@echo off
|
setlocal enableextensions
|
rem Semantic vault search via the local Miyo CLI; prints Miyo's JSON to stdout.
|
if "%~1"=="" (
|
echo Usage: miyo-search.cmd "query" 1>&2
|
exit /b 1
|
)
|
set "MIYO=%LOCALAPPDATA%\Miyo\bin\miyo\miyo.exe"
|
if not exist "%MIYO%" (
|
set "MIYO="
|
where miyo >nul 2>&1 && set "MIYO=miyo"
|
)
|
if not defined MIYO (
|
echo Miyo CLI not found. The Miyo desktop app is not installed - tell the user to install Miyo, then retry. Do not retry in a loop. 1>&2
|
exit /b 3
|
)
|
"%MIYO%" search %* -n 10 --json
|