kimaki 0.4.15 → 0.4.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +2 -5
- package/dist/discordBot.js +8 -0
- package/package.json +1 -1
- package/src/cli.ts +2 -5
- package/src/discordBot.ts +8 -0
- package/src/opencode-command-upload-to-discord.md +0 -22
package/dist/cli.js
CHANGED
|
@@ -629,20 +629,17 @@ cli
|
|
|
629
629
|
}
|
|
630
630
|
});
|
|
631
631
|
cli
|
|
632
|
-
.command('install-plugin', 'Install the OpenCode
|
|
632
|
+
.command('install-plugin', 'Install the OpenCode command for kimaki Discord integration')
|
|
633
633
|
.action(async () => {
|
|
634
634
|
try {
|
|
635
635
|
const require = createRequire(import.meta.url);
|
|
636
636
|
const sendCommandSrc = require.resolve('./opencode-command-send-to-discord.md');
|
|
637
|
-
const uploadCommandSrc = require.resolve('./opencode-command-upload-to-discord.md');
|
|
638
637
|
const opencodeConfig = path.join(os.homedir(), '.config', 'opencode');
|
|
639
638
|
const commandDir = path.join(opencodeConfig, 'command');
|
|
640
639
|
fs.mkdirSync(commandDir, { recursive: true });
|
|
641
640
|
const sendCommandDest = path.join(commandDir, 'send-to-kimaki-discord.md');
|
|
642
|
-
const uploadCommandDest = path.join(commandDir, 'upload-to-discord.md');
|
|
643
641
|
fs.copyFileSync(sendCommandSrc, sendCommandDest);
|
|
644
|
-
|
|
645
|
-
note(`Commands installed:\n- ${sendCommandDest}\n- ${uploadCommandDest}\n\nUse /send-to-kimaki-discord to send session to Discord.\nUse /upload-to-discord to upload files to the thread.`, '✅ Installed');
|
|
642
|
+
note(`Command installed:\n- ${sendCommandDest}\n\nUse /send-to-kimaki-discord to send session to Discord.`, '✅ Installed');
|
|
646
643
|
process.exit(0);
|
|
647
644
|
}
|
|
648
645
|
catch (error) {
|
package/dist/discordBot.js
CHANGED
|
@@ -41,6 +41,14 @@ The user is reading your messages from inside Discord, via kimaki.xyz
|
|
|
41
41
|
|
|
42
42
|
Your current OpenCode session ID is: ${sessionId}
|
|
43
43
|
|
|
44
|
+
## uploading files to discord
|
|
45
|
+
|
|
46
|
+
To upload files (images, screenshots, etc.) to the Discord thread, run:
|
|
47
|
+
|
|
48
|
+
npx -y kimaki upload-to-discord --session ${sessionId} <file1> [file2] ...
|
|
49
|
+
|
|
50
|
+
## showing diffs
|
|
51
|
+
|
|
44
52
|
After each message, if you implemented changes, you can show the user a diff via an url running the command, to show the changes in working directory:
|
|
45
53
|
|
|
46
54
|
bunx critique web
|
package/package.json
CHANGED
package/src/cli.ts
CHANGED
|
@@ -931,12 +931,11 @@ cli
|
|
|
931
931
|
})
|
|
932
932
|
|
|
933
933
|
cli
|
|
934
|
-
.command('install-plugin', 'Install the OpenCode
|
|
934
|
+
.command('install-plugin', 'Install the OpenCode command for kimaki Discord integration')
|
|
935
935
|
.action(async () => {
|
|
936
936
|
try {
|
|
937
937
|
const require = createRequire(import.meta.url)
|
|
938
938
|
const sendCommandSrc = require.resolve('./opencode-command-send-to-discord.md')
|
|
939
|
-
const uploadCommandSrc = require.resolve('./opencode-command-upload-to-discord.md')
|
|
940
939
|
|
|
941
940
|
const opencodeConfig = path.join(os.homedir(), '.config', 'opencode')
|
|
942
941
|
const commandDir = path.join(opencodeConfig, 'command')
|
|
@@ -944,13 +943,11 @@ cli
|
|
|
944
943
|
fs.mkdirSync(commandDir, { recursive: true })
|
|
945
944
|
|
|
946
945
|
const sendCommandDest = path.join(commandDir, 'send-to-kimaki-discord.md')
|
|
947
|
-
const uploadCommandDest = path.join(commandDir, 'upload-to-discord.md')
|
|
948
946
|
|
|
949
947
|
fs.copyFileSync(sendCommandSrc, sendCommandDest)
|
|
950
|
-
fs.copyFileSync(uploadCommandSrc, uploadCommandDest)
|
|
951
948
|
|
|
952
949
|
note(
|
|
953
|
-
`
|
|
950
|
+
`Command installed:\n- ${sendCommandDest}\n\nUse /send-to-kimaki-discord to send session to Discord.`,
|
|
954
951
|
'✅ Installed',
|
|
955
952
|
)
|
|
956
953
|
|
package/src/discordBot.ts
CHANGED
|
@@ -82,6 +82,14 @@ The user is reading your messages from inside Discord, via kimaki.xyz
|
|
|
82
82
|
|
|
83
83
|
Your current OpenCode session ID is: ${sessionId}
|
|
84
84
|
|
|
85
|
+
## uploading files to discord
|
|
86
|
+
|
|
87
|
+
To upload files (images, screenshots, etc.) to the Discord thread, run:
|
|
88
|
+
|
|
89
|
+
npx -y kimaki upload-to-discord --session ${sessionId} <file1> [file2] ...
|
|
90
|
+
|
|
91
|
+
## showing diffs
|
|
92
|
+
|
|
85
93
|
After each message, if you implemented changes, you can show the user a diff via an url running the command, to show the changes in working directory:
|
|
86
94
|
|
|
87
95
|
bunx critique web
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Upload files to Discord thread
|
|
3
|
-
---
|
|
4
|
-
Upload files to the current Discord thread by running:
|
|
5
|
-
|
|
6
|
-
```bash
|
|
7
|
-
npx -y kimaki upload-to-discord --session <sessionId> <file1> [file2] [file3] ...
|
|
8
|
-
```
|
|
9
|
-
|
|
10
|
-
Replace `<sessionId>` with your current OpenCode session ID (available in the system prompt).
|
|
11
|
-
|
|
12
|
-
Examples:
|
|
13
|
-
|
|
14
|
-
```bash
|
|
15
|
-
# Upload a single file
|
|
16
|
-
npx -y kimaki upload-to-discord --session ses_abc123 ./screenshot.png
|
|
17
|
-
|
|
18
|
-
# Upload multiple files
|
|
19
|
-
npx -y kimaki upload-to-discord --session ses_abc123 ./image1.png ./image2.jpg ./document.pdf
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
The session must have been sent to Discord first using `/send-to-kimaki-discord`.
|