From 139f053c5b5a7e22575b1a189ef8da305abdfaa4 Mon Sep 17 00:00:00 2001 From: remiliacn Date: Sun, 30 May 2021 11:25:08 -0500 Subject: [PATCH 1/8] Fix: Image won't load in README.md --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b80da92..6124806 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@

- go-cqhttp + + go-cqhttp +

@@ -285,4 +287,4 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1 ## 性能 -在关闭数据库的情况下, 加载 25 个好友 128 个群运行 24 小时后内存使用为 15MB 左右. 开启数据库后内存使用将根据消息量增加 10-20MB, 如果系统内存小于 128M 建议关闭数据库使用. \ No newline at end of file +在关闭数据库的情况下, 加载 25 个好友 128 个群运行 24 小时后内存使用为 15MB 左右. 开启数据库后内存使用将根据消息量增加 10-20MB, 如果系统内存小于 128M 建议关闭数据库使用. From 9d44697dcd8e6309f685c4ffef1e339c03ac6e8d Mon Sep 17 00:00:00 2001 From: Shigma <1700011071@pku.edu.cn> Date: Mon, 31 May 2021 00:54:23 +0800 Subject: [PATCH 2/8] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 6124806..026af85 100644 --- a/README.md +++ b/README.md @@ -44,7 +44,7 @@ _✨ 基于 [Mirai](https://github.com/mamoe/mirai) 以及 [MiraiGo](https://git ## 兼容性 -go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v11/specs)绝大多数内容,并在其基础上做了一些扩展,详情请看go-cqhttp的文档 +go-cqhttp 兼容 [OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v11/specs) 绝大多数内容,并在其基础上做了一些扩展,详情请看 go-cqhttp 的文档。 ### 接口 @@ -68,7 +68,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1 ### 实现
-已实现CQ码 +已实现 CQ 码 #### 符合 Onebot 标准的 CQ 码 @@ -122,7 +122,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1
-已实现API +已实现 API #### 符合 Onebot 标准的 API @@ -219,7 +219,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1
-已实现Event +已实现 Event #### 符合 Onebot 标准的 Event(部分 Event 比 Onebot 标准多上报几个字段,不影响使用) From 9c17a3e1c820657a593545bbdc09aed9cf4cdd7c Mon Sep 17 00:00:00 2001 From: Shigma <1700011071@pku.edu.cn> Date: Mon, 31 May 2021 00:59:17 +0800 Subject: [PATCH 3/8] Update README.md --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 6124806..d2839ad 100644 --- a/README.md +++ b/README.md @@ -50,8 +50,8 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1 - [x] HTTP API - [x] 反向 HTTP POST -- [x] 正向 Websocket -- [x] 反向 Websocket +- [x] 正向 WebSocket +- [x] 反向 WebSocket ### 拓展支持 @@ -70,7 +70,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1
已实现CQ码 -#### 符合 Onebot 标准的 CQ 码 +#### 符合 OneBot 标准的 CQ 码 | CQ 码 | 功能 | | ------------ | --------------------------- | @@ -99,7 +99,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1 [xml 消息]: https://github.com/howmanybots/onebot/blob/master/v11/specs/message/segment.md#xml-%E6%B6%88%E6%81%AF [json 消息]: https://github.com/howmanybots/onebot/blob/master/v11/specs/message/segment.md#json-%E6%B6%88%E6%81%AF -#### 拓展 CQ 码及与 Onebot 标准有略微差异的 CQ 码 +#### 拓展 CQ 码及与 OneBot 标准有略微差异的 CQ 码 | 拓展 CQ 码 | 功能 | | -------------- | --------------------------------- | @@ -124,7 +124,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1
已实现API -#### 符合 Onebot 标准的 API +#### 符合 OneBot 标准的 API | API | 功能 | | ------------------------ | ---------------------- | @@ -184,7 +184,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1 [重启 go-cqhttp]: https://github.com/howmanybots/onebot/blob/master/v11/specs/api/public.md#set_restart-%E9%87%8D%E5%90%AF-onebot-%E5%AE%9E%E7%8E%B0 [对事件执行快速操作]: https://github.com/howmanybots/onebot/blob/master/v11/specs/api/hidden.md#handle_quick_operation-%E5%AF%B9%E4%BA%8B%E4%BB%B6%E6%89%A7%E8%A1%8C%E5%BF%AB%E9%80%9F%E6%93%8D%E4%BD%9C -#### 拓展 API 及与 Onebot 标准有略微差异的 API +#### 拓展 API 及与 OneBot 标准有略微差异的 API | 拓展 API | 功能 | | --------------------------- | ---------------------- | @@ -221,7 +221,7 @@ go-cqhttp兼容[OneBot-v11](https://github.com/howmanybots/onebot/tree/master/v1
已实现Event -#### 符合 Onebot 标准的 Event(部分 Event 比 Onebot 标准多上报几个字段,不影响使用) +#### 符合 OneBot 标准的 Event(部分 Event 比 OneBot 标准多上报几个字段,不影响使用) | 事件类型 | Event | | -------- | ---------------- | From ad7e53009d6850cdb4fb597294d6852e09702ef3 Mon Sep 17 00:00:00 2001 From: Mrs4s Date: Fri, 2 Jul 2021 09:46:15 +0800 Subject: [PATCH 4/8] fix device lock. --- login.go | 1 + 1 file changed, 1 insertion(+) diff --git a/login.go b/login.go index 12690ef..f74469a 100644 --- a/login.go +++ b/login.go @@ -130,6 +130,7 @@ func loginResponseProcessor(res *client.LoginResponse) error { continue } cli.Disconnect() + cli = client.NewClientEmpty() return qrcodeLogin() case client.NeedCaptcha: log.Warnf("登录需要验证码.") From 8bfbfc04f3a96a229caebbf9f17c2682d5255a74 Mon Sep 17 00:00:00 2001 From: yume233 Date: Sat, 3 Jul 2021 17:55:46 +0800 Subject: [PATCH 5/8] =?UTF-8?q?=E7=BC=93=E5=AD=98=E4=BE=9D=E8=B5=96,?= =?UTF-8?q?=E4=BC=98=E5=8C=96CI=E7=BC=96=E8=AF=91=E9=80=9F=E5=BA=A6,?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=89=8B=E5=8A=A8=E8=A7=A6=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/ci.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a5fc0bd..77b92f6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,6 +1,6 @@ name: CI -on: [push, pull_request] +on: [push, pull_request,workflow_dispatch] env: BINARY_PREFIX: "go-cqhttp_" @@ -31,6 +31,13 @@ jobs: uses: actions/setup-go@v2.1.3 with: go-version: 1.16 + - name: Cache downloaded module + uses: actions/cache@v2 + with: + path: | + ~/.cache/go-build + ~/go/pkg/mod + key: ${{ runner.os }}-go-${{ matrix.goos }}-${{ matrix.goarch }}-${{ hashFiles('**/go.sum') }} - name: Build binary file env: GOOS: ${{ matrix.goos }} From a894ee91bc7d883aa52a63b18de21556cc056bc5 Mon Sep 17 00:00:00 2001 From: umia Date: Sat, 3 Jul 2021 20:03:39 +0800 Subject: [PATCH 6/8] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E4=BE=9D=E8=B5=96?= =?UTF-8?q?=E7=BC=93=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/suggester.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/suggester.yml b/.github/workflows/suggester.yml index b427f2f..a61f13b 100644 --- a/.github/workflows/suggester.yml +++ b/.github/workflows/suggester.yml @@ -18,6 +18,14 @@ jobs: uses: golangci/golangci-lint-action@v2 with: version: latest + + - name: Cache downloaded module + uses: actions/cache@v2 + with: + path: | + ~/.cache/go-build + ~/go/pkg/mod + key: ${{ runner.os }}-go-${{ matrix.goos }}-${{ matrix.goarch }}-${{ hashFiles('**/go.sum') }} - name: Tests run: | From 5d00bd134d55fc0b9e48a23b222756e7301d287f Mon Sep 17 00:00:00 2001 From: umia Date: Sat, 3 Jul 2021 20:04:12 +0800 Subject: [PATCH 7/8] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E4=BE=9D=E8=B5=96?= =?UTF-8?q?=E7=BC=93=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/golint.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/golint.yml b/.github/workflows/golint.yml index 206a42c..fe3d785 100644 --- a/.github/workflows/golint.yml +++ b/.github/workflows/golint.yml @@ -18,6 +18,14 @@ jobs: uses: golangci/golangci-lint-action@v2 with: version: latest + + - name: Cache downloaded module + uses: actions/cache@v2 + with: + path: | + ~/.cache/go-build + ~/go/pkg/mod + key: ${{ runner.os }}-go-${{ matrix.goos }}-${{ matrix.goarch }}-${{ hashFiles('**/go.sum') }} - name: Tests run: | From f6e5e28a7a0ccb3c7ac87ccaea0fea03fc7078cc Mon Sep 17 00:00:00 2001 From: umia Date: Sat, 3 Jul 2021 20:07:24 +0800 Subject: [PATCH 8/8] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=89=8B=E5=8A=A8?= =?UTF-8?q?=E8=A7=A6=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/golint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/golint.yml b/.github/workflows/golint.yml index fe3d785..4e03fff 100644 --- a/.github/workflows/golint.yml +++ b/.github/workflows/golint.yml @@ -1,6 +1,6 @@ name: Lint -on: [push] +on: [push,workflow_dispatch] jobs: golangci: