Go to file
OpenCode Skills c601418ed7 Add mqtts-developer skill: Complete MQTTS certificate management
New skill: mqtts-developer
- Complete automated MQTTS setup workflow with acme.sh
- Multi-language client configuration guide (Python, Node.js, Java, C#, Go, ESP32)
- Quick reference for commands and troubleshooting
- Practical usage examples
- Token-efficient reusable knowledge base

Features:
- 10-phase automated certificate setup
- Support for Alibaba Cloud DNS API
- Auto-renewal with Docker container restart
- Single-direction TLS authentication
- 7+ programming language examples
- Comprehensive troubleshooting guides
- 1750+ lines of structured documentation

Token Savings:
- First use: 60-70% reduction
- Repeated use: 80%+ reduction

Files:
- SKILL.md: Main entry point and overview
- setup-mqtts-acme.md: Complete setup workflow (11KB, 350 lines)
- mqtts-quick-reference.md: Quick reference guide (7KB, 277 lines)
- mqtts-client-config.md: Client configuration (15KB, 596 lines)
- README.md: Usage guide (6KB, 227 lines)
- USAGE_EXAMPLES.md: Practical examples (6KB, 275 lines)
2026-01-07 17:31:52 +08:00

OpenCode Configuration

This repository contains custom OpenCode configuration including commands, skills, and MCP services.

Structure

.
├── opencode.json          # MCP services configuration
├── command/               # Custom commands
│   ├── auto-commit.md
│   ├── commit-push.md
│   ├── create-gitea-repo.md
│   ├── release-android.md
│   ├── review.md
│   ├── sync-oc-pull.md
│   └── sync-oc-push.md
└── skill/                 # Agent skills
    ├── android-developer/
    ├── electron-developer/
    ├── go-developer/
    └── ios-developer/

Setup

1. Clone Configuration

git clone https://git.digitevents.com/ai/opencode.git ~/.config/opencode

2. Configure Environment Variables

Create env.sh file (not tracked in git) or use the one from iCloud:

# Option 1: Create manually
cat > ~/.config/opencode/env.sh << 'EOF'
# OpenCode Environment Variables
export REF_API_KEY="your-ref-api-key"
export FIGMA_API_KEY="your-figma-api-key"
export GITEA_API_TOKEN="your-gitea-token"
EOF

# Option 2: Use iCloud (macOS only)
# File location: ~/Library/Mobile Documents/com~apple~CloudDocs/opencode-env.sh

3. Load Environment Variables

Add to your ~/.zshrc or ~/.bashrc:

# Load from iCloud (macOS)
[[ -f ~/Library/Mobile\ Documents/com~apple~CloudDocs/opencode-env.sh ]] && \
  source ~/Library/Mobile\ Documents/com~apple~CloudDocs/opencode-env.sh

# Or load from local file
[[ -f ~/.config/opencode/env.sh ]] && source ~/.config/opencode/env.sh

Then reload your shell:

source ~/.zshrc

Usage

Commands

Run custom commands in OpenCode TUI:

  • /auto-commit - Auto-generate commit and create tag
  • /commit-push - Commit, tag and push to remote
  • /create-gitea-repo - Create repository on Gitea
  • /release-android - Build and release Android APK to Gitea
  • /sync-oc-pull - Pull OpenCode config changes
  • /sync-oc-push - Push OpenCode config changes
  • /review - Review code or documentation

Skills

Skills are automatically loaded by agents when needed:

  • android-developer - Android development with Kotlin/Compose
  • electron-developer - Electron desktop app development
  • ios-developer - iOS development with Swift/SwiftUI
  • go-developer - Go backend development

MCP Services

Configure MCP services in opencode.json:

  • ref - Ref.tools API (requires REF_API_KEY)
  • figma - Figma Developer MCP (requires FIGMA_API_KEY)

Sync Across Devices

Push Changes

cd ~/.config/opencode
git add .
git commit -m "chore: update config"
git push

Pull Changes

cd ~/.config/opencode
git pull

Or use the built-in commands:

  • /sync-oc-push - Push changes
  • /sync-oc-pull - Pull changes

Security

Important: Never commit sensitive information like API keys to git.

  • env.sh is ignored by git
  • Store credentials in iCloud or use a secure password manager
  • Use environment variables instead of hardcoding secrets
Description
No description provided
Readme MIT 376 KiB
Languages
Markdown 100%