日常更新

This commit is contained in:
Dvel
2023-02-25 04:51:22 +08:00
parent 196a0ea7a6
commit b445204425
10 changed files with 120 additions and 48 deletions

View File

@@ -13,7 +13,6 @@ func main() {
// 临时用的
// rime.Temp()
// return
// Emoji 检查和更新
rime.CheckEmoji()

View File

@@ -12,6 +12,37 @@ import (
// 临时用的或一次性的方法集
func Temp() {
defer os.Exit(1)
enFile, err := os.Open(EnPath)
if err != nil {
log.Fatal(err)
}
defer enFile.Close()
file, err := os.Create("1.txt")
if err != nil {
log.Fatal(err)
}
defer file.Close()
sc := bufio.NewScanner(enFile)
isMark := false
for sc.Scan() {
line := sc.Text()
if !isMark {
if strings.HasPrefix(line, "# +_+") {
isMark = true
}
continue
}
parts := strings.Split(line, "\t")
s := fmt.Sprintf("%s\t_%s_\t-1\n", parts[0], parts[1])
file.WriteString(s)
}
file.Sync()
}
func dictsDifference(dict1, dict2 string) {

View File

@@ -1,3 +1,8 @@
布维岛
女士凉鞋
华尔滋
萌萌达
萌萌嗒
黏连
粘蛋白
粘粘