abcex up
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing

This commit is contained in:
Arnas Udovic 2025-01-07 08:26:35 +02:00
parent d62efd6844
commit 57cfdf3e16
3 changed files with 6 additions and 6 deletions

2
go.mod
View file

@ -3,7 +3,7 @@ module g.arns.lt/zordsdavini/zord-tree
go 1.21 go 1.21
require ( require (
g.arns.lt/zordsdavini/abcex/v3 v3.0.0 g.arns.lt/zordsdavini/abcex/v4 v4.0.4
github.com/otiai10/copy v1.6.0 github.com/otiai10/copy v1.6.0
golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1 golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1
) )

4
go.sum
View file

@ -1,5 +1,5 @@
g.arns.lt/zordsdavini/abcex/v3 v3.0.0 h1:LnlDtaBBOpgicMI/dcBUxlu4r4+IFt/MD19JemphgFc= g.arns.lt/zordsdavini/abcex/v4 v4.0.4 h1:idjvgkCjrjZfDxLyOcX7lCIdIndISDAkj77VCvhu8/c=
g.arns.lt/zordsdavini/abcex/v3 v3.0.0/go.mod h1:z2xqDlRFVnLMnCGpqRjbs9T9EY6lJKJnQmU3zJLSNq8= g.arns.lt/zordsdavini/abcex/v4 v4.0.4/go.mod h1:/+//gYSUtJrdsmTtWNoffRO4xD1BuPRUMGW4ynet7iE=
github.com/otiai10/copy v1.6.0 h1:IinKAryFFuPONZ7cm6T6E2QX/vcJwSnlaA5lfoaXIiQ= github.com/otiai10/copy v1.6.0 h1:IinKAryFFuPONZ7cm6T6E2QX/vcJwSnlaA5lfoaXIiQ=
github.com/otiai10/copy v1.6.0/go.mod h1:XWfuS3CrI0R6IE0FbgHsEazaXO8G0LpMp9o8tos0x4E= github.com/otiai10/copy v1.6.0/go.mod h1:XWfuS3CrI0R6IE0FbgHsEazaXO8G0LpMp9o8tos0x4E=
github.com/otiai10/curr v0.0.0-20150429015615-9b4961190c95/go.mod h1:9qAhocn7zKJG+0mI8eUu6xqkFDYS2kb2saOteoSB3cE= github.com/otiai10/curr v0.0.0-20150429015615-9b4961190c95/go.mod h1:9qAhocn7zKJG+0mI8eUu6xqkFDYS2kb2saOteoSB3cE=

View file

@ -15,7 +15,7 @@ import (
"regexp" "regexp"
"strings" "strings"
abcex "g.arns.lt/zordsdavini/abcex/v3" abcex "g.arns.lt/zordsdavini/abcex/v4"
"golang.org/x/exp/slices" "golang.org/x/exp/slices"
) )
@ -386,7 +386,7 @@ func addMissingId(dir string, id int64) error {
break break
} }
if line == "---" { if line == "---" {
err = addMeta(path, "id", abcex.Encode(id)) err = addMeta(path, "id", abcex.Encode(id, abcex.BASE36))
if err != nil { if err != nil {
return err return err
} }
@ -440,7 +440,7 @@ func getMaxId(dir string) (int64, error) {
if strings.HasPrefix(line, "* id:") { if strings.HasPrefix(line, "* id:") {
line = strings.TrimPrefix(line, "* id:") line = strings.TrimPrefix(line, "* id:")
i := abcex.Decode(strings.Trim(line, " ")) i := abcex.Decode(strings.Trim(line, " "), abcex.BASE36)
if i > max { if i > max {
max = i max = i
} }