mirror of
https://github.com/bendtherules/opencode-multi-model.git
synced 2026-08-18 21:52:11 +00:00
Compare commits
7
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
49da7c4219 | ||
|
|
41757e712f | ||
|
|
96e3922c42 | ||
|
|
d6a2811ec4 | ||
|
|
c179491aed | ||
|
|
1b8f54d955 | ||
|
|
7cecbede6d |
@@ -13,7 +13,7 @@ Add to your OpenCode config (`opencode.json`):
|
|||||||
|
|
||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
"plugin": ["@username/opencode-multi-model"]
|
"plugin": ["opencode-multi-model"]
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -21,10 +21,10 @@ Add to your OpenCode config (`opencode.json`):
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Using bunx (no install)
|
# Using bunx (no install)
|
||||||
bunx @username/opencode-multi-model open my-session -m openai/gpt-5.2 anthropic/claude-3-5-sonnet
|
bunx opencode-multi-model open my-session -m openai/gpt-5.2 anthropic/claude-3-5-sonnet
|
||||||
|
|
||||||
# Or install globally
|
# Or install globally
|
||||||
bun install -g @username/opencode-multi-model
|
bun install -g opencode-multi-model
|
||||||
opencode-multi-model open my-session -m openai/gpt-5.2
|
opencode-multi-model open my-session -m openai/gpt-5.2
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -34,7 +34,7 @@ If you installed it via bun and want to use it as a project tool, import it from
|
|||||||
|
|
||||||
```typescript
|
```typescript
|
||||||
// .opencode/tools/multi-model.ts
|
// .opencode/tools/multi-model.ts
|
||||||
import { openTool as open, closeTool as close } from "@username/opencode-multi-model"
|
import { openTool as open, closeTool as close } from "opencode-multi-model"
|
||||||
export { open, close }
|
export { open, close }
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
+4
-3
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@username/opencode-multi-model",
|
"name": "opencode-multi-model",
|
||||||
"version": "1.0.0",
|
"version": "0.0.3",
|
||||||
"description": "Launch multiple AI models in tmux sessions - OpenCode Plugin, CLI, and Project Tool",
|
"description": "Launch multiple AI models in tmux sessions - OpenCode Plugin, CLI, and Project Tool",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/index.js",
|
"main": "./dist/index.js",
|
||||||
@@ -19,7 +19,8 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "bun build src/index.ts src/cli.ts --outdir dist --target bun --format esm",
|
"build": "bun build src/index.ts src/cli.ts --outdir dist --target bun --format esm",
|
||||||
"test": "bun test",
|
"test": "bun test",
|
||||||
"prepublishOnly": "bun run build"
|
"prepublishOnly": "bun run build",
|
||||||
|
"release": "bash ./scripts/release.sh"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@opencode-ai/plugin": "^1.2.27",
|
"@opencode-ai/plugin": "^1.2.27",
|
||||||
|
|||||||
Executable
+39
@@ -0,0 +1,39 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Prompt for version bump type
|
||||||
|
read -p "Select version bump (major/minor/patch): " bump
|
||||||
|
if [[ ! "$bump" =~ ^(major|minor|patch)$ ]]; then
|
||||||
|
echo "Invalid choice. Must be 'major', 'minor', or 'patch'."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Run tests
|
||||||
|
echo "Running test suite..."
|
||||||
|
npm test
|
||||||
|
|
||||||
|
# Build the project
|
||||||
|
echo "Building the project..."
|
||||||
|
npm run build
|
||||||
|
|
||||||
|
# Bump version
|
||||||
|
echo "Bumping version ($bump)..."
|
||||||
|
npm version "$bump" -m "chore(release): %s"
|
||||||
|
|
||||||
|
# Show git status
|
||||||
|
git status
|
||||||
|
|
||||||
|
# Confirm publishing
|
||||||
|
read -p "Proceed with npm publish? (y/N): " confirm
|
||||||
|
if [[ "$confirm" != "y" && "$confirm" != "Y" ]]; then
|
||||||
|
echo "Publish aborted."
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Publish to npm
|
||||||
|
npm publish
|
||||||
|
|
||||||
|
# Push git commits and tags
|
||||||
|
git push && git push --tags
|
||||||
|
|
||||||
|
echo "Release completed successfully."
|
||||||
Reference in New Issue
Block a user