Skip to content

Commit 10eb534

Browse files
committed
feat: update dependencies and refactor configuration structure
- Updated @opencode-ai/plugin from 1.0.0 to 1.2.24 - Updated @types/node from 25.3.3 to 25.4.0 - Updated typescript from 5.0.0 to 5.9.3 - Changed config.commands to config.command for consistency - Removed redundant commands section from plugin definition
1 parent a6a1c6c commit 10eb534

File tree

3 files changed

+20
-33
lines changed

3 files changed

+20
-33
lines changed

package-lock.json

Lines changed: 14 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,11 @@
3838
"url": "https://github.com/roman-pinchuk/opencode-codetime/issues"
3939
},
4040
"peerDependencies": {
41-
"@opencode-ai/plugin": ">=1.0.0"
41+
"@opencode-ai/plugin": "^1.2.24"
4242
},
4343
"devDependencies": {
44-
"@opencode-ai/plugin": "^1.0.0",
45-
"@types/node": "^25.3.3",
46-
"typescript": "^5.0.0"
44+
"@opencode-ai/plugin": "1.2.24",
45+
"@types/node": "^25.4.0",
46+
"typescript": "^5.9.3"
4747
}
4848
}

src/index.ts

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -364,8 +364,8 @@ export const plugin: Plugin = async (ctx) => {
364364
},
365365

366366
config: async (cfg: any) => {
367-
cfg.commands = cfg.commands || {};
368-
cfg.commands["codetime"] = {
367+
cfg.command = cfg.command || {};
368+
cfg.command["codetime"] = {
369369
description: "Show today's coding time from CodeTime",
370370
template:
371371
"Retrieve CodeTime coding time stats.\n\n" +
@@ -377,19 +377,6 @@ export const plugin: Plugin = async (ctx) => {
377377
};
378378
},
379379

380-
commands: {
381-
codetime: {
382-
description: "Show today's coding time from CodeTime",
383-
template:
384-
"Retrieve CodeTime coding time stats.\n\n" +
385-
"Based on the arguments provided: `$ARGUMENTS`\n\n" +
386-
'- If no arguments (empty/blank), call `codetime` with `project: "current"` to show current project time.\n' +
387-
"- If the argument is `breakdown`, call `codetime` with `breakdown: true` to show all projects.\n" +
388-
"- Otherwise, call `codetime` with `project` set to the argument value to show that specific project's time.\n\n" +
389-
"IMPORTANT: Return ONLY the exact output from the codetime tool, with absolutely no additional text, formatting, markdown, explanation, or commentary before or after it. Do not wrap it in code blocks. Do not add any other text.",
390-
},
391-
},
392-
393380
tool: {
394381
codetime: tool({
395382
description:

0 commit comments

Comments
 (0)