1
0
mirror of https://github.com/FloatTech/zbpdata.git synced 2026-02-16 12:15:53 +09:00

Compare commits

..

9 Commits

Author SHA1 Message Date
源文雨
dc8f73dee4 add zbpwife 2023-03-25 15:40:09 +08:00
源文雨
0d0fa3f435 add zbpwife 2023-03-25 14:27:54 +08:00
源文雨
5a511a6d63 add zbpwife 2023-03-25 14:24:56 +08:00
源文雨
d15c4b8a09 Merge branch 'main' of https://github.com/FloatTech/zbpdata into main 2023-03-25 14:21:52 +08:00
源文雨
095ee1ae8e add zbpwife 2023-03-25 14:21:06 +08:00
苜蓿紫
d640b5f0f1 添加猫啃珠圆体 (#38) 2023-03-20 12:17:36 +08:00
源文雨
b9848c9a4e update to go1.20 2023-02-27 13:59:20 +08:00
himawari
e2a91d6160 添加一言数据库 2023-02-26 12:00:21 +08:00
himawari
4506005ebc 添加一言数据库 2023-02-26 11:50:54 +08:00
7 changed files with 17 additions and 4 deletions

View File

@@ -11,18 +11,25 @@ jobs:
- name: Checkout - name: Checkout
uses: actions/checkout@v2.3.4 uses: actions/checkout@v2.3.4
with: with:
submodules: 'true'
fetch-depth: 0 fetch-depth: 0
- name: Set up Go - name: Set up Go
uses: actions/setup-go@v2 uses: actions/setup-go@v2
with: with:
go-version: '1.19' go-version: '1.20'
- name: Run Updater - name: Run Updater
env: env:
REILIA_SPS: ${{ secrets.REILIA_SPS }} REILIA_SPS: ${{ secrets.REILIA_SPS }}
run: | run: |
echo "ls ./"
ls ls
rm Wife/go.* Wife/*.go Wife/*.md
mv Wife/wives/*.{jpg,png} Wife/
rm -rf Wife/wives Wife/.git
echo "ls Wife/"
ls Wife/
go mod init updater go mod init updater
sed -i '1,3d' main.go sed -i '1,3d' main.go
go mod tidy go mod tidy

3
.gitmodules vendored Normal file
View File

@@ -0,0 +1,3 @@
[submodule "Wife"]
path = Wife
url = https://github.com/FloatTech/zbpwife

Binary file not shown.

BIN
Font/MaokenZhuyuanTi.ttf Normal file

Binary file not shown.

BIN
Hitokoto/hitokoto.db Normal file

Binary file not shown.

1
Wife Submodule

Submodule Wife added at abcf931871

View File

@@ -13,6 +13,7 @@ import (
"unicode" "unicode"
"unsafe" "unsafe"
"github.com/FloatTech/floatbox/process"
"github.com/fumiama/go-registry" "github.com/fumiama/go-registry"
"github.com/wdvxdr1123/ZeroBot/utils/helper" "github.com/wdvxdr1123/ZeroBot/utils/helper"
) )
@@ -45,18 +46,19 @@ func main() {
panic(err) panic(err)
} }
for i, fn := range files { for i, fn := range files {
for c := 0; c < 5; c++ { for c := 0; c < 16; c++ {
err = r.Set("data/"+fn, md5s[i]) err = r.Set("data/"+fn, md5s[i])
fmt.Println("set", "data/"+fn, "=", hex.EncodeToString(helper.StringToBytes(md5s[i]))) fmt.Println("set", "data/"+fn, "=", hex.EncodeToString(helper.StringToBytes(md5s[i])))
if err == nil { if err == nil {
break break
} }
if c >= 4 { if c >= 15 {
panic("ERROR:" + err.Error() + "max retry times exceeded") panic("ERROR:" + err.Error() + ", max retry times exceeded")
} else { } else {
fmt.Println("ERROR:", err, ", retry times:", c) fmt.Println("ERROR:", err, ", retry times:", c)
} }
_ = r.Close() _ = r.Close()
process.SleepAbout1sTo2s()
err = r.Connect() err = r.Connect()
if err != nil { if err != nil {
panic(err) panic(err)