alemonjs 1.0.39 → 1.0.40

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.
Files changed (54) hide show
  1. package/lib/config/login.js +6 -6
  2. package/lib/core/apps.js +4 -4
  3. package/lib/core/dealmsg.js +9 -9
  4. package/lib/core/puppeteer.js +15 -15
  5. package/lib/core/qrcode.js +2 -2
  6. package/lib/core/screenshot.js +3 -3
  7. package/lib/default/types.js +1 -16
  8. package/lib/define/command.js +1 -1
  9. package/lib/define/main.js +4 -1
  10. package/lib/define/map.js +4 -4
  11. package/lib/koa/client.js +4 -4
  12. package/lib/koa/img.js +2 -2
  13. package/lib/kook/alemon/conversation.js +2 -2
  14. package/lib/kook/index.js +1 -1
  15. package/lib/kook/kook.js +1 -1
  16. package/lib/kook/login.js +2 -2
  17. package/lib/kook/sdk/ws.js +12 -12
  18. package/lib/log/event.js +2 -2
  19. package/lib/log/user.js +2 -2
  20. package/lib/login.js +1 -1
  21. package/lib/ntqq/alemon/message/C2C_MESSAGE_CREATE.js +3 -3
  22. package/lib/ntqq/alemon/message/GROUP_AT_MESSAGE_CREATE.js +3 -3
  23. package/lib/ntqq/index.js +1 -1
  24. package/lib/ntqq/login.js +5 -5
  25. package/lib/ntqq/ntqq.js +17 -1
  26. package/lib/ntqq/sdk/wss.js +12 -12
  27. package/lib/qq/alemon/conversation.js +10 -13
  28. package/lib/qq/alemon/e.js +4 -4
  29. package/lib/qq/alemon/message/DIRECT_MESSAGE.js +2 -2
  30. package/lib/qq/alemon/message/GUILD_MEMBERS.js +2 -2
  31. package/lib/qq/login.js +2 -2
  32. package/lib/qq/qq.js +1 -1
  33. package/lib/qq/sdk/wss.js +5 -5
  34. package/lib/run.js +2 -2
  35. package/lib/villa/alemon/conversation.js +1 -1
  36. package/lib/villa/alemon/message/e.js +4 -4
  37. package/lib/villa/index.js +1 -1
  38. package/lib/villa/login.js +2 -2
  39. package/lib/villa/sdk/client.js +9 -9
  40. package/lib/villa/sdk/hs.js +1 -1
  41. package/lib/villa/villa.js +1 -1
  42. package/package.json +1 -1
  43. package/run.js +2 -2
  44. package/types/config/types.d.ts +9 -6
  45. package/types/default/types.d.ts +27 -157
  46. package/types/define/types.d.ts +7 -3
  47. package/types/kook/kook.d.ts +20 -2
  48. package/types/ntqq/ntqq.d.ts +72 -4
  49. package/types/qq/qq.d.ts +44 -2
  50. package/types/villa/villa.d.ts +52 -2
  51. package/lib/default/typings.js +0 -1
  52. package/lib/ntqq/sdk/types.js +0 -1
  53. package/types/default/typings.d.ts +0 -50
  54. package/types/ntqq/sdk/types.d.ts +0 -11
package/lib/ntqq/login.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { setBotConfigByKey, getBotConfigByKey } from '../config/index.js';
2
- import { NtQQEventsEnum } from '../default/types.js';
2
+ import { NTQQEventsEnum } from './ntqq.js';
3
3
  /**
4
4
  * 登录配置
5
5
  * @param Bcf
@@ -12,14 +12,14 @@ export async function checkRobotByQQ() {
12
12
  (config.token ?? '') !== '') {
13
13
  if (!config.intents) {
14
14
  config.intents = [
15
- NtQQEventsEnum.GROUP_AT_MESSAGE_CREATE,
16
- NtQQEventsEnum.C2C_MESSAGE_CREATE
15
+ NTQQEventsEnum.GROUP_AT_MESSAGE_CREATE,
16
+ NTQQEventsEnum.C2C_MESSAGE_CREATE
17
17
  ];
18
18
  }
19
19
  setBotConfigByKey('ntqq', config);
20
20
  return true;
21
21
  }
22
- console.error('[AlemonJS]', '[LOGIN]', '-----------------------');
23
- console.error('[AlemonJS]', '[LOGIN]', 'ntqq配置加载失败~');
22
+ console.error('login', '-----------------------');
23
+ console.error('login', 'NTQQ config err');
24
24
  return false;
25
25
  }
package/lib/ntqq/ntqq.js CHANGED
@@ -1,4 +1,20 @@
1
- export default {
1
+ /**
2
+ * *****
3
+ * ntqq订阅
4
+ * ****
5
+ */
6
+ export var NTQQEventsEnum;
7
+ (function (NTQQEventsEnum) {
8
+ /**
9
+ * 群聊消息
10
+ */
11
+ NTQQEventsEnum["GROUP_AT_MESSAGE_CREATE"] = "GROUP_AT_MESSAGE_CREATE";
12
+ /**
13
+ * 单聊消息
14
+ */
15
+ NTQQEventsEnum["C2C_MESSAGE_CREATE"] = "C2C_MESSAGE_CREATE";
16
+ })(NTQQEventsEnum = NTQQEventsEnum || (NTQQEventsEnum = {}));
17
+ export const defineNtqq = {
2
18
  appID: '',
3
19
  token: '',
4
20
  secret: '',
@@ -15,11 +15,11 @@ export async function getGatewayUrl() {
15
15
  return response.url;
16
16
  }
17
17
  else {
18
- console.error('[AlemonJS]', '[http] err:', null);
18
+ console.error('http err:', null);
19
19
  }
20
20
  }
21
21
  catch (error) {
22
- console.error('[AlemonJS]', '[token] err:', error.message);
22
+ console.error('token err:', error.message);
23
23
  }
24
24
  }
25
25
  let reconnectAttempts = 0; // 重新连接计数器
@@ -36,10 +36,10 @@ export async function createClient(call, shard = [0, 1]) {
36
36
  // 重新连接的逻辑
37
37
  const reconnect = async () => {
38
38
  if (reconnectAttempts >= 5) {
39
- console.info('[AlemonJS]', '已达到最大重连次数,取消重新连接');
39
+ console.info('The maximum number of reconnections has been reached, cancel reconnection');
40
40
  return;
41
41
  }
42
- console.info('[AlemonJS]', '正在重新连接...');
42
+ console.info('reconnecting...');
43
43
  // 延迟一段时间后发起重新连接
44
44
  await new Promise(resolve => setTimeout(resolve, 5000));
45
45
  // 调用createClient函数重新建立连接
@@ -49,7 +49,7 @@ export async function createClient(call, shard = [0, 1]) {
49
49
  if (gatewayUrl) {
50
50
  const ws = new WebSocket(gatewayUrl);
51
51
  ws.on('open', () => {
52
- console.info('[AlemonJS]', '[token] ok');
52
+ console.info('token ok');
53
53
  });
54
54
  /**
55
55
  * 标记是否已连接
@@ -98,19 +98,19 @@ export async function createClient(call, shard = [0, 1]) {
98
98
  }
99
99
  // Resumed Event,恢复连接成功
100
100
  if (t === 'RESUMED') {
101
- console.info('[AlemonJS]', '恢复连接');
101
+ console.info('restore connection');
102
102
  // 重制次数
103
103
  reconnectAttempts = 0;
104
104
  }
105
105
  break;
106
106
  }
107
107
  case 6: {
108
- console.info('[AlemonJS]', '[连接尝试]', message);
108
+ console.info('connection attempt', message);
109
109
  break;
110
110
  }
111
111
  case 7: {
112
112
  // 执行重新连接
113
- console.info('[AlemonJS]', '[重新连接]', message);
113
+ console.info('reconnect', message);
114
114
  // 取消鉴权发送
115
115
  if (power) {
116
116
  clearInterval(power);
@@ -119,7 +119,7 @@ export async function createClient(call, shard = [0, 1]) {
119
119
  break;
120
120
  }
121
121
  case 9: {
122
- console.info('[AlemonJS]', '[参数错误]', message);
122
+ console.info('parameter error', message);
123
123
  break;
124
124
  }
125
125
  case 10: {
@@ -148,16 +148,16 @@ export async function createClient(call, shard = [0, 1]) {
148
148
  }
149
149
  case 11: {
150
150
  // OpCode 11 Heartbeat ACK 消息,心跳发送成功
151
- console.info('[AlemonJS]', '[心跳发送]', message);
151
+ console.info('heartbeat transmission', message);
152
152
  break;
153
153
  }
154
154
  case 12: {
155
- console.info('[AlemonJS]', '[平台数据]', message);
155
+ console.info('platform data', message);
156
156
  }
157
157
  }
158
158
  });
159
159
  ws.on('close', () => {
160
- console.info('[AlemonJS]', '[ws] close');
160
+ console.info('[ws] close');
161
161
  });
162
162
  }
163
163
  }
@@ -23,7 +23,7 @@ export const createConversationByQQ = ws => {
23
23
  ws.on(SessionEvents.READY, async (data) => {
24
24
  const cfg = getBotConfigByKey('qq');
25
25
  if (cfg.sandbox)
26
- console.info('[AlemonJS]', '[READY]', data);
26
+ console.info('ready', data);
27
27
  const robot = data.msg;
28
28
  const bot = {
29
29
  id: robot.user.id,
@@ -81,59 +81,56 @@ export const createConversationByQQ = ws => {
81
81
  * 审核事件监听
82
82
  */
83
83
  ws.on(AvailableIntentsEventsEnum.AUDIO_ACTION, AUDIO_ACTION);
84
- console.info('[AlemonJS]', '[QQ]', ` 欢迎回来 ${bot.name}`);
84
+ console.info('qq', 'Welcome back', bot.name);
85
85
  });
86
86
  /**
87
87
  * 权限错误
88
88
  */
89
89
  ws.on(SessionEvents.ERROR, (one) => {
90
- console.error('[AlemonJS]', '[ERROR]', one);
90
+ console.error('err', one);
91
91
  });
92
92
  /**
93
93
  * 超长断连
94
94
  */
95
95
  ws.on(SessionEvents.DEAD, (one) => {
96
- console.error('[AlemonJS]', 'DEAD', one);
97
- console.error('[AlemonJS]', '请确认配置!');
98
- console.error('[AlemonJS]', '账户密码是否正确?');
99
- console.error('[AlemonJS]', '域事件是否匹配?');
96
+ console.error('dead', one);
100
97
  });
101
98
  /**
102
99
  * 关闭
103
100
  */
104
101
  ws.on(SessionEvents.CLOSED, (one) => {
105
- console.error('[AlemonJS]', '[CLOSED]', one);
102
+ console.error('close', one);
106
103
  });
107
104
  /**
108
105
  * 断开连接
109
106
  */
110
107
  ws.on(SessionEvents.DISCONNECT, (one) => {
111
- console.error('[AlemonJS]', '[DISCONNECT]', one);
108
+ console.error('disconnect', one);
112
109
  });
113
110
  /**
114
111
  * 无效会话
115
112
  */
116
113
  ws.on(SessionEvents.INVALID_SESSION, (one) => {
117
- console.error('[AlemonJS]', '[INVALID_SESSION]', one);
114
+ console.error('invalid session', one);
118
115
  });
119
116
  /**
120
117
  * 再连接
121
118
  */
122
119
  ws.on(SessionEvents.RECONNECT, (one) => {
123
- console.error('[AlemonJS]', '[RECONNECT]', one);
120
+ console.error('reconnect', one);
124
121
  });
125
122
  /**
126
123
  * 重新开始
127
124
  */
128
125
  ws.on(SessionEvents.RESUMED, (one) => {
129
- console.error('[AlemonJS]', '[RESUMED]', one);
126
+ console.error('resumed', one);
130
127
  });
131
128
  /**
132
129
  * WS断连
133
130
  */
134
131
  ws.on(SessionEvents.EVENT_WS, async (one) => {
135
132
  if (one.eventType == 'DISCONNECT') {
136
- console.info('[AlemonJS]', '[EVENT_WS][DISCONNECT]', one);
133
+ console.info('ws disconnect', one);
137
134
  }
138
135
  });
139
136
  };
@@ -5,7 +5,7 @@ export const now_e = {
5
5
  * @returns
6
6
  */
7
7
  replyCard: async (obj) => {
8
- console.info('[AlemonJS]', '待实现');
8
+ console.info('to be implemented');
9
9
  return false;
10
10
  },
11
11
  /**
@@ -15,7 +15,7 @@ export const now_e = {
15
15
  * @returns
16
16
  */
17
17
  replyByMid: async (mid, msg) => {
18
- console.info('[AlemonJS]', '待实现');
18
+ console.info('to be implemented');
19
19
  return false;
20
20
  },
21
21
  /**
@@ -25,7 +25,7 @@ export const now_e = {
25
25
  * @returns
26
26
  */
27
27
  replyEmoji: async (mid, boj) => {
28
- console.info('[AlemonJS]', '待实现');
28
+ console.info('to be implemented');
29
29
  return false;
30
30
  },
31
31
  /**
@@ -35,7 +35,7 @@ export const now_e = {
35
35
  * @returns
36
36
  */
37
37
  deleteEmoji: async (mid, boj) => {
38
- console.info('[AlemonJS]', '待实现');
38
+ console.info('to be implemented');
39
39
  return false;
40
40
  }
41
41
  };
@@ -146,7 +146,7 @@ async function directMessage(e, event) {
146
146
  * @returns
147
147
  */
148
148
  e.replyEmoji = async (mid, boj) => {
149
- console.info('[AlemonJS]', '不可用');
149
+ console.info('temporarily unavailable');
150
150
  return false;
151
151
  };
152
152
  /**
@@ -156,7 +156,7 @@ async function directMessage(e, event) {
156
156
  * @returns
157
157
  */
158
158
  e.deleteEmoji = async (mid, boj) => {
159
- console.info('[AlemonJS]', '不可用');
159
+ console.info('temporarily unavailable');
160
160
  return false;
161
161
  };
162
162
  e.msg_txt = event.msg.content;
@@ -41,11 +41,11 @@ export const GUILD_MEMBERS = async (event) => {
41
41
  })
42
42
  .catch(error);
43
43
  if (typeof ChannelsData == 'boolean') {
44
- console.info('[AlemonJS]', `[${Eevent}] [${eventType}] ${false}`);
44
+ console.info(`[${Eevent}] [${eventType}] ${false}`);
45
45
  return false;
46
46
  }
47
47
  if (ChannelsData.length == 0) {
48
- console.info('[AlemonJS]', `[${Eevent}] [${eventType}] ${false}`);
48
+ console.info(`[${Eevent}] [${eventType}] ${false}`);
49
49
  return false;
50
50
  }
51
51
  const ChannelData = ChannelsData.find(item => item.type === 0);
package/lib/qq/login.js CHANGED
@@ -21,7 +21,7 @@ export async function checkRobotByQQ() {
21
21
  setBotConfigByKey('qq', config);
22
22
  return true;
23
23
  }
24
- console.error('[AlemonJS]', '[LOGIN]', '-----------------------');
25
- console.error('[AlemonJS]', '[LOGIN]', 'QQ配置加载失败~');
24
+ console.error('login', '-----------------------');
25
+ console.error('login', 'QQ config err');
26
26
  return false;
27
27
  }
package/lib/qq/qq.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { AvailableIntentsEventsEnum } from 'qq-guild-bot';
2
- export default {
2
+ export const defineQQ = {
3
3
  appID: '',
4
4
  token: '',
5
5
  secret: '',
package/lib/qq/sdk/wss.js CHANGED
@@ -15,11 +15,11 @@ export async function getGatewayUrl() {
15
15
  return response.url;
16
16
  }
17
17
  else {
18
- console.error('[AlemonJS]', '[http] err:', null);
18
+ console.error('http err:', null);
19
19
  }
20
20
  }
21
21
  catch (error) {
22
- console.error('[AlemonJS]', '[token] err:', error.message);
22
+ console.error('token err:', error.message);
23
23
  }
24
24
  }
25
25
  /**
@@ -35,7 +35,7 @@ export async function createClient(callBack) {
35
35
  if (gatewayUrl) {
36
36
  const ws = new WebSocket(gatewayUrl);
37
37
  ws.on('open', () => {
38
- console.info('[AlemonJS]', '[token] ok');
38
+ console.info('token ok');
39
39
  });
40
40
  /**
41
41
  * 标记是否已连接
@@ -116,7 +116,7 @@ export async function createClient(callBack) {
116
116
  }
117
117
  case 11: {
118
118
  // OpCode 11 Heartbeat ACK 消息,心跳发送成功
119
- console.info('[AlemonJS]', '心跳发送成功~');
119
+ console.info('heartbeat transmission');
120
120
  break;
121
121
  }
122
122
  case 12: {
@@ -125,7 +125,7 @@ export async function createClient(callBack) {
125
125
  }
126
126
  });
127
127
  ws.on('close', () => {
128
- console.error('[AlemonJS]', '[ws] close');
128
+ console.error('ws close');
129
129
  });
130
130
  }
131
131
  }
package/lib/run.js CHANGED
@@ -11,13 +11,13 @@ export function commandRun(ars) {
11
11
  const argsWithoutFiles = msg.replace(/(\S+\.js|\S+\.ts)/g, '');
12
12
  for (const item of files) {
13
13
  if (!existsSync(join(process.cwd(), item))) {
14
- console.info('[AlemonJS]', '[NO FILE]', item);
14
+ console.info('no file', item);
15
15
  continue;
16
16
  }
17
17
  const isTypeScript = item.endsWith('.ts');
18
18
  const command = isTypeScript ? 'npx ts-node' : 'node';
19
19
  const cmd = `${command} ${item} ${argsWithoutFiles}`;
20
- console.info('[AlemonJS]', cmd);
20
+ console.info(cmd);
21
21
  const childProcess = spawn(cmd, { shell: true });
22
22
  childProcess.stdout.on('data', data => {
23
23
  process.stdout.write(data.toString());
@@ -42,7 +42,7 @@ export async function callBackByVilla(event) {
42
42
  return await ConversationMap[event.type](event);
43
43
  }
44
44
  else {
45
- // console.info('[新事件触发]', event.type)
45
+ // console.info('[new event triggering]', event.type)
46
46
  return;
47
47
  }
48
48
  }
@@ -5,7 +5,7 @@ export const now_e = {
5
5
  * @returns
6
6
  */
7
7
  replyCard: async (arr) => {
8
- console.info('[AlemonJS]', '待实现');
8
+ console.info('to be implemented');
9
9
  return false;
10
10
  },
11
11
  /**
@@ -15,7 +15,7 @@ export const now_e = {
15
15
  * @returns
16
16
  */
17
17
  replyByMid: async (mid, msg) => {
18
- console.info('[AlemonJS]', '待实现');
18
+ console.info('to be implemented');
19
19
  return false;
20
20
  },
21
21
  /**
@@ -25,7 +25,7 @@ export const now_e = {
25
25
  * @returns
26
26
  */
27
27
  replyEmoji: async (mid, boj) => {
28
- console.info('[AlemonJS]', '待实现');
28
+ console.info('to be implemented');
29
29
  return false;
30
30
  },
31
31
  /**
@@ -35,7 +35,7 @@ export const now_e = {
35
35
  * @returns
36
36
  */
37
37
  deleteEmoji: async (mid, boj) => {
38
- console.info('[AlemonJS]', '待实现');
38
+ console.info('to be implemented');
39
39
  return false;
40
40
  }
41
41
  };
@@ -20,7 +20,7 @@ export async function createAlemonByVilla() {
20
20
  callback_port: cfg.port ?? 8080,
21
21
  callback_url: cfg.url ?? '/api/mys/callback'
22
22
  }, callBackByVilla, async () => {
23
- console.info('[AlemonJS]', '[HELLO] 欢迎使用大别野');
23
+ console.info('VILLA Welcome back');
24
24
  });
25
25
  return true;
26
26
  }
@@ -15,7 +15,7 @@ export async function checkRobotByVilla() {
15
15
  setBotConfigByKey('villa', config);
16
16
  return true;
17
17
  }
18
- console.error('[AlemonJS]', '[LOGIN]', '-----------------------');
19
- console.error('[AlemonJS]', '[LOGIN]', 'VILLA配置加载失败~');
18
+ console.error('login', '-----------------------');
19
+ console.error('login', 'VILLA config err');
20
20
  return false;
21
21
  }
@@ -39,11 +39,11 @@ export function createClient({ bot_id, bot_secret, callback_url = '/api/mys/call
39
39
  /**
40
40
  * 处理完毕后返回响应
41
41
  */
42
- ctx.body = { message: '错误回调', retcode: 0 };
42
+ ctx.body = { message: 'error callback', retcode: 0 };
43
43
  return;
44
44
  }
45
45
  await callBack(event).catch(err => {
46
- console.error('[AlemonJS]', '回调出错');
46
+ console.error('callback error');
47
47
  console.error(err);
48
48
  });
49
49
  }
@@ -52,11 +52,11 @@ export function createClient({ bot_id, bot_secret, callback_url = '/api/mys/call
52
52
  /**
53
53
  * 处理完毕后返回响应
54
54
  */
55
- ctx.body = { message: '执行错误', retcode: 0 };
55
+ ctx.body = { message: 'execution error', retcode: 0 };
56
56
  return;
57
57
  }
58
58
  // 处理完毕后返回响应
59
- ctx.body = { message: '处理完成', retcode: 0 };
59
+ ctx.body = { message: 'processing completed', retcode: 0 };
60
60
  });
61
61
  /**
62
62
  * 将路由注册到应用
@@ -72,17 +72,17 @@ export function createClient({ bot_id, bot_secret, callback_url = '/api/mys/call
72
72
  */
73
73
  function handlePortConflict(err) {
74
74
  if (err.code === 'EADDRINUSE') {
75
- console.error('[AlemonJS]', `端口 ${currentPort} 被占用,尝试启动新的端口...`);
75
+ console.error(`port ${currentPort} occupied, attempting to start a new port...`);
76
76
  currentPort++;
77
77
  size++;
78
78
  if (size >= 10) {
79
- console.error('[AlemonJS]', '寻端失败~');
79
+ console.error('find port err');
80
80
  return;
81
81
  }
82
82
  createApp(currentPort);
83
83
  }
84
84
  else {
85
- console.error('[AlemonJS]', '启动应用程序时发生错误:', err);
85
+ console.error('an error occurred while starting the application', err);
86
86
  }
87
87
  }
88
88
  /**
@@ -110,10 +110,10 @@ export function createClient({ bot_id, bot_secret, callback_url = '/api/mys/call
110
110
  // 获取ip4
111
111
  const ip = await getIP();
112
112
  if (ip) {
113
- console.info('[AlemonJS]', '[VILLA OPEN]', `http://${ip}:${port ?? 8080}${callback_url ?? '/api/mys/callback'}`);
113
+ console.info('villa open', `http://${ip}:${port ?? 8080}${callback_url ?? '/api/mys/callback'}`);
114
114
  }
115
115
  else {
116
- console.error('[AlemonJS]', '[VILLA] 公网IP识别失败,无法支持运行');
116
+ console.error('vllia no public ip');
117
117
  return;
118
118
  }
119
119
  })
@@ -14,7 +14,7 @@ export function hmacSha256(secret, pubKey) {
14
14
  return Buffer.from(rawHmac).toString('hex');
15
15
  }
16
16
  catch (e) {
17
- console.error('[AlemonJS]', '加密错误');
17
+ console.error('encryption error');
18
18
  throw new Error(e);
19
19
  }
20
20
  }
@@ -1,4 +1,4 @@
1
- export default {
1
+ export const defineVILLA = {
2
2
  bot_id: '',
3
3
  secret: '',
4
4
  pub_key: '',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "alemonjs",
3
- "version": "1.0.39",
3
+ "version": "1.0.40",
4
4
  "description": "DOCS https://alemonjs.com/",
5
5
  "author": "ningmengchongshui",
6
6
  "license": "GPL-2.0",
package/run.js CHANGED
@@ -11,13 +11,13 @@ export function commandRun(ars) {
11
11
  const argsWithoutFiles = msg.replace(/(\S+\.js|\S+\.ts)/g, '')
12
12
  for (const item of files) {
13
13
  if (!existsSync(join(process.cwd(), item))) {
14
- console.log('[NO FILE]', item)
14
+ console.log('no file', item)
15
15
  continue
16
16
  }
17
17
  const isTypeScript = item.endsWith('.ts')
18
18
  const command = isTypeScript ? 'npx ts-node' : 'node'
19
19
  const cmd = `${command} ${item} ${argsWithoutFiles}`
20
- console.log('[alemonjs]', cmd)
20
+ console.log(cmd)
21
21
  const childProcess = spawn(cmd, { shell: true })
22
22
  childProcess.stdout.on('data', data => {
23
23
  process.stdout.write(data.toString())
@@ -1,7 +1,10 @@
1
1
  import { PuppeteerLaunchOptions } from 'puppeteer';
2
- import { KookOptionsg, NtQQOptions, QqGuildOptions, VillaOptions } from '../default/types.js';
3
- import { MysqlOptions, RedisOptions } from '../default/typings.js';
2
+ import { MysqlOptions, RedisOptions } from '../default/types.js';
4
3
  import { ServerOptions } from '../koa/types.js';
4
+ import { KOOKOptions } from '../kook/kook.js';
5
+ import { VILLAOptions } from '../villa/villa.js';
6
+ import { QQOptions } from '../qq/qq.js';
7
+ import { NTQQOptions } from '../ntqq/ntqq.js';
5
8
  /**
6
9
  * ******
7
10
  * config
@@ -10,10 +13,10 @@ import { ServerOptions } from '../koa/types.js';
10
13
  export interface ConfigType {
11
14
  redis: RedisOptions;
12
15
  mysql: MysqlOptions;
13
- kook: KookOptionsg;
14
- villa: VillaOptions;
15
- qq: QqGuildOptions;
16
+ kook: KOOKOptions;
17
+ villa: VILLAOptions;
18
+ qq: QQOptions;
16
19
  server: ServerOptions;
17
20
  puppeteer: PuppeteerLaunchOptions;
18
- ntqq: NtQQOptions;
21
+ ntqq: NTQQOptions;
19
22
  }