mirror of
https://github.com/xr843/Master-skill.git
synced 2026-05-10 13:26:25 +00:00
f3472d6254
Add support for 5 platforms beyond NPX: - Claude Code: .claude-plugin/plugin.json + marketplace.json - Cursor: .cursor-plugin/plugin.json + hooks-cursor.json - Codex CLI: .codex/INSTALL.md with symlink setup - OpenCode: .opencode/INSTALL.md with plugin config - Gemini CLI: gemini-extension.json + GEMINI.md Infrastructure: - SessionStart hook with platform detection (Claude Code, Cursor, Copilot CLI) that injects available masters list - Cross-platform run-hook.cmd polyglot wrapper (Windows + Unix) - .version-bump.json for unified version management across all platform config files - Update README/README_EN with multi-platform install instructions Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
30 lines
662 B
Batchfile
Executable File
30 lines
662 B
Batchfile
Executable File
: ; # Polyglot wrapper — runs as cmd.exe on Windows, bash on Unix
|
|
: ; exec bash "$0" "$@" 2>/dev/null
|
|
: ; exit
|
|
@echo off
|
|
setlocal enabledelayedexpansion
|
|
|
|
set "HOOK=%~1"
|
|
set "HOOK_DIR=%~dp0"
|
|
|
|
:: Try common Git for Windows bash locations
|
|
for %%B in (
|
|
"C:\Program Files\Git\bin\bash.exe"
|
|
"C:\Program Files (x86)\Git\bin\bash.exe"
|
|
"%LOCALAPPDATA%\Programs\Git\bin\bash.exe"
|
|
) do (
|
|
if exist %%B (
|
|
%%B "%HOOK_DIR%%HOOK%" %2 %3 %4 %5
|
|
exit /b %ERRORLEVEL%
|
|
)
|
|
)
|
|
|
|
:: Fallback: try bash from PATH
|
|
where bash >nul 2>&1 && (
|
|
bash "%HOOK_DIR%%HOOK%" %2 %3 %4 %5
|
|
exit /b %ERRORLEVEL%
|
|
)
|
|
|
|
:: No bash found — exit silently
|
|
exit /b 0
|