fix: replace hardcoded ~/.desirecore paths with ${DESIRECORE_ROOT} variable (#16)

## Summary

- 将所有技能文件中的硬编码 `~/.desirecore/` 和 `$HOME/.desirecore/` 路径替换为
`${DESIRECORE_ROOT}/` 变量
- 递增 manifest.json version 至 1.2.1

## Why

dev 模式下 `DESIRECORE_HOME=~/.desirecore-dev`,硬编码路径导致技能读取错误的端口文件和目录。主仓库的
`variable-substitutor.ts` 会在运行时将 `${DESIRECORE_ROOT}` 替换为实际根目录。

## Test plan

- [ ] `npm run dev` 启动后触发任意技能,确认端口路径解析为
`~/.desirecore-dev/agent-service.port`
- [ ] prod 模式确认路径为 `~/.desirecore/agent-service.port`

🤖 Generated with [Claude Code](https://claude.com/claude-code)
This commit is contained in:
2026-05-29 15:36:19 +08:00
committed by GitHub
parent 3015a3ffb8
commit 4f7037a6b6
52 changed files with 192 additions and 192 deletions

View File

@@ -118,7 +118,7 @@ Example lyrics format:
**Note: Do not pass the `output_format` parameter; use the default hex format.**
```bash
PORT=$(cat ~/.desirecore/agent-service.port)
PORT=$(cat ${DESIRECORE_ROOT}/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
@@ -142,7 +142,7 @@ curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
### Generate Pure Instrumental
```bash
PORT=$(cat ~/.desirecore/agent-service.port)
PORT=$(cat ${DESIRECORE_ROOT}/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
@@ -198,7 +198,7 @@ The API returns JSON; audio data is hex-encoded and stored in the `data.data.aud
Extract the hex string from the `data.data.audio.data` field of the response JSON, convert it to binary, and upload:
```bash
PORT=$(cat ~/.desirecore/agent-service.port)
PORT=$(cat ${DESIRECORE_ROOT}/agent-service.port)
# Save the API response to a temporary file (avoid letting large hex data overflow shell variables)
# Assume the curl output of the previous step has been saved to /tmp/minimax-music-resp.json
@@ -256,7 +256,7 @@ Example: `"独立民谣,温暖治愈,木吉他为主,轻柔的鼓点,渐进式
If the user only describes the desired music style without providing lyrics, set `lyrics_optimizer: true` and the model will auto-generate lyrics from the prompt:
```bash
PORT=$(cat ~/.desirecore/agent-service.port)
PORT=$(cat ${DESIRECORE_ROOT}/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{