chore: init

This commit is contained in:
DevMiner 2024-08-11 03:51:22 +02:00
commit 320715f3e7
174 changed files with 42083 additions and 0 deletions

View file

@ -0,0 +1,22 @@
package helpers
import (
"crypto/sha256"
"time"
)
func HashSHA256(data []byte) []byte {
h := sha256.New()
h.Write(data)
return h.Sum(nil)
}
func ISO8601(t time.Time) string {
return t.Format("2006-01-02T15:04:05Z")
}
func ParseISO8601(s string) (time.Time, error) {
return time.Parse("2006-01-02T15:04:05Z", s)
}

5
internal/helpers/ptr.go Normal file
View file

@ -0,0 +1,5 @@
package helpers
func StringPtr(s string) *string {
return &s
}