Skip to content

Commit 8ba3518

Browse files
committed
chore: update package metadata and build config
1 parent 0484532 commit 8ba3518

2 files changed

Lines changed: 54 additions & 36 deletions

File tree

README.md

Lines changed: 26 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -15,39 +15,36 @@ An OpenCode plugin that integrates OpenSpec, providing a dedicated agent for pla
1515

1616
## Installation
1717

18-
You don't need to build this plugin yourself. You can install it via npm or download the pre-built binary.
18+
### Option 1: Install from NPM (Recommended)
1919

20-
### Option 1: Install via npm (Recommended)
20+
Simply add the plugin package name to your `opencode.json` configuration file (usually located at `~/.config/opencode/opencode.json` or `.opencode/opencode.json`):
2121

22-
1. Install the plugin globally:
23-
```bash
24-
npm install -g opencode-plugin-openspec
25-
```
22+
```json
23+
{
24+
"plugin": [
25+
"opencode-plugin-openspec"
26+
]
27+
}
28+
```
2629

27-
2. Add it to your `opencode.json` (usually in `~/.config/opencode/opencode.json` or `.opencode/opencode.json`):
30+
OpenCode will automatically download and install the plugin the next time it runs.
2831

29-
```json
30-
{
31-
"plugin": [
32-
"opencode-plugin-openspec"
33-
]
34-
}
35-
```
36-
*(Note: If OpenCode doesn't support package names directly, you may need to provide the full path, e.g., `$(npm root -g)/opencode-plugin-openspec/dist/index.js`)*
37-
38-
### Option 2: Download from Releases
39-
40-
1. Go to the [Releases](https://github.com/yourusername/opencode-plugin-openspec/releases) page.
41-
2. Download the latest `index.js`.
42-
3. Place it anywhere on your disk.
43-
4. Add the path to your `opencode.json`:
44-
```json
45-
{
46-
"plugin": [
47-
"/absolute/path/to/downloaded/index.js"
48-
]
49-
}
50-
```
32+
### Option 2: Manual / Local Installation
33+
34+
If you want to install from a local build or a specific file:
35+
36+
1. Build the project:
37+
```bash
38+
bun run build
39+
```
40+
2. Add the absolute path to your `opencode.json`:
41+
```json
42+
{
43+
"plugin": [
44+
"file:///absolute/path/to/opencode-plugin-openspec/dist/index.js"
45+
]
46+
}
47+
```
5148

5249
## Usage
5350

@@ -58,8 +55,6 @@ You don't need to build this plugin yourself. You can install it via npm or down
5855

5956
## Development
6057

61-
If you want to contribute or modify the plugin, follow these steps:
62-
6358
1. Clone the repository:
6459
```bash
6560
git clone https://github.com/yourusername/opencode-plugin-openspec.git

package.json

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,39 @@
11
{
22
"name": "opencode-plugin-openspec",
33
"version": "0.1.0",
4+
"description": "An OpenCode plugin that integrates OpenSpec, providing a dedicated agent for planning and specifying software architecture.",
45
"type": "module",
5-
"main": "src/index.ts",
6+
"main": "dist/index.js",
7+
"files": [
8+
"dist"
9+
],
10+
"scripts": {
11+
"build": "bun build ./src/index.ts --outfile ./dist/index.js --target node",
12+
"watch": "bun build ./src/index.ts --outfile ./dist/index.js --target node --watch",
13+
"prepublishOnly": "bun run build"
14+
},
15+
"repository": {
16+
"type": "git",
17+
"url": "git+https://github.com/Octane0411/opencode-plugin-openspec.git"
18+
},
19+
"keywords": [
20+
"opencode",
21+
"plugin",
22+
"openspec",
23+
"agent",
24+
"architecture",
25+
"planning"
26+
],
27+
"author": "Octane0411",
28+
"license": "MIT",
29+
"bugs": {
30+
"url": "https://github.com/Octane0411/opencode-plugin-openspec/issues"
31+
},
32+
"homepage": "https://github.com/Octane0411/opencode-plugin-openspec#readme",
633
"peerDependencies": {
734
"@opencode-ai/plugin": "^1.1.19",
835
"@opencode-ai/sdk": "^1.1.19"
936
},
10-
"scripts": {
11-
"build": "bun build ./src/index.ts --outfile ./dist/index.js --target node",
12-
"watch": "bun build ./src/index.ts --outfile ./dist/index.js --target node --watch"
13-
},
1437
"devDependencies": {
1538
"bun-types": "latest",
1639
"typescript": "^5.0.0"

0 commit comments

Comments
 (0)