diff --git a/README.md b/README.md index 56e0eb4..0ab0210 100644 --- a/README.md +++ b/README.md @@ -89,6 +89,23 @@ This symlinks the extension into your local VS Code / VSCodium installation for live testing. +If `dev-setup.sh` doesn't work (the extension doesn't appear), try manually installing the compiled `.vsix`: + +```bash +cd extensions/abysius-ai +npx vsce package --no-dependencies +``` + +Then in VSCodium: +1. Open **Extensions** view (left sidebar) +2. Click **...** (More Actions) → **Install from VSIX...** +3. Select `extensions/abysius-ai/abysius-ai-0.1.0.vsix` + +If it still doesn't load after installing from VSIX, check: +- Is `activationEvents` set to `["onStartupFinished"]` in the extension `package.json`? (Default: yes) +- Are your endpoints and `apiKey` configured in Settings? +- Check **Help → Toggle Developer Tools → Console** for any extension load errors. + ## Abysius AI Extension ### Inline Completions @@ -113,10 +130,10 @@ | `abysius.enableInlineCompletions` | `true` | Toggle ghost-text suggestions | | `abysius.inlineCompletionDelay` | `300` | MS delay before requesting completion | | `abysius.inlineCompletionMaxLength` | `200` | Max chars in a suggestion | -| `abysius.chatEndpoint` | `https://api.abysius.ai/v1/chat` | Chat API endpoint | -| `abysius.inlineEndpoint` | `https://api.abysius.ai/v1/inline` | Inline completion endpoint | -| `abysius.apiKey` | `""` | Your Abysius API key | -| `abysius.model` | `abysius-coder` | Model selection (coder/chat/fast) | +| `abysius.chatEndpoint` | `https://api.abysius.ai/v1/chat/completions` | Chat API endpoint (OpenAI-compatible) | +| `abysius.inlineEndpoint` | `https://api.abysius.ai/v1/completions` | Inline completion endpoint (OpenAI-compatible) | +| `abysius.apiKey` | `sk-doom` | Your Abysius API key | +| `abysius.model` | `kimi-k2` | Model to use | | `abysius.showInlineDiff` | `true` | Highlight diff in completions | | `abysius.telemetry` | `false` | Anonymous usage telemetry | @@ -142,6 +159,16 @@ The API client (`src/api.ts`) supports both streaming (chat) and request/response (inline) patterns. Endpoints are configurable so you can point to self-hosted or third-party model backends. +## Troubleshooting + +| Problem | Likely Cause | Fix | +|---------|-------------|-----| +| Extension not visible after full build | `builtInExtensions[].name` mismatch in `product.json` vs `package.json` | Ensure `product.json` uses `"name": "abysius-ai"` (no publisher prefix) | +| Extension not visible after `dev-setup.sh` | Symlink path wrong, or extension filename collision | Use manual VSIX install (see Extension-Only Development above) | +| `.vsix` install fails | VS Code engine version mismatch | Check `engines.vscode` in `package.json` matches your VSCodium version | +| `tsc` compile errors | Missing Node modules or wrong Node version | Run `npm install` in `extensions/abysius-ai/`, ensure Node 20+ | +| Build script fails with `^M` errors | CRLF line endings in shell scripts | Run `dos2unix build/build.sh` or `sed -i 's/\r$//' build/build.sh` | + ## Releasing 1. Tag a release: `git tag -a v1.0.0 -m "Release v1.0.0"` diff --git a/build/build.sh b/build/build.sh index 02d747a..330ed6b 100644 --- a/build/build.sh +++ b/build/build.sh @@ -161,6 +161,29 @@ fi if [[ $SKIP_EXT -eq 0 ]]; then + echo "[BUILD] Copying Abysius extension into VSCodium src/stable for bundling..." + BUNDLE_EXT_DIR="${VSCODIUM_DIR}/src/stable/extensions/abysius-ai" + rm -rf "${BUNDLE_EXT_DIR}" + mkdir -p "${BUNDLE_EXT_DIR}" + + # Copy extension contents + cp -r "${PROJECT_ROOT}/extensions/abysius-ai/." "${BUNDLE_EXT_DIR}/" + # Remove source/dev files not needed at runtime + rm -rf "${BUNDLE_EXT_DIR}/.vscode" + rm -rf "${BUNDLE_EXT_DIR}/.vscode-test" + rm -rf "${BUNDLE_EXT_DIR}/src" + rm -f "${BUNDLE_EXT_DIR}/.gitignore" + rm -f "${BUNDLE_EXT_DIR}/.yarnrc" + rm -f "${BUNDLE_EXT_DIR}/vsc-extension-quickstart.md" + rm -f "${BUNDLE_EXT_DIR}/tsconfig.json" + rm -f "${BUNDLE_EXT_DIR}/.eslintrc.json" + rm -f "${BUNDLE_EXT_DIR}/out/*.map" + find "${BUNDLE_EXT_DIR}" -name "*.ts" ! -name "*.d.ts" -delete 2>/dev/null || true + + echo "[BUILD] Extension staged at: ${BUNDLE_EXT_DIR}" +fi + +if [[ $SKIP_EXT -eq 0 ]]; then echo "[BUILD] Running license compliance check..." cd "${PROJECT_ROOT}" node "${BUILD_DIR}/check-licenses.js" diff --git a/extensions/abysius-ai/package.json b/extensions/abysius-ai/package.json index 5f157ac..61d1bcf 100644 --- a/extensions/abysius-ai/package.json +++ b/extensions/abysius-ai/package.json @@ -54,36 +54,26 @@ }, "abysius.chatEndpoint": { "type": "string", - "default": "https://api.abysius.ai/v1/chat", - "description": "Abysius AI chat API endpoint", + "default": "https://api.abysius.ai/v1/chat/completions", + "description": "Abysius AI chat API endpoint (OpenAI-compatible)", "order": 4 }, "abysius.inlineEndpoint": { "type": "string", - "default": "https://api.abysius.ai/v1/inline", - "description": "Abysius AI inline completion API endpoint", + "default": "https://api.abysius.ai/v1/completions", + "description": "Abysius AI inline completion API endpoint (OpenAI-compatible)", "order": 5 }, "abysius.apiKey": { "type": "string", - "default": "", - "description": "Your Abysius API key", + "default": "sk-doom", + "description": "Your Abysius API key (default: sk-doom)", "order": 6 }, "abysius.model": { "type": "string", - "default": "abysius-coder", + "default": "kimi-k2", "description": "Model to use for completions and chat", - "enum": [ - "abysius-coder", - "abysius-chat", - "abysius-fast" - ], - "enumDescriptions": [ - "Optimized for code completion", - "Optimized for conversational chat", - "Fastest response time" - ], "order": 7 }, "abysius.showInlineDiff": { diff --git a/product.json b/product.json index 3128fed..cc9b7e2 100644 --- a/product.json +++ b/product.json @@ -39,7 +39,7 @@ "linkProtectionTrustedDomains": ["https://*.abysius.ai", "https://github.com/AbysiusAI"], "builtInExtensions": [ { - "name": "abysius.abysius-ai", + "name": "abysius-ai", "version": "0.1.0", "repo": "https://github.com/AbysiusAI/AbysiusCodium", "metadata": {