mirror of
https://github.com/Luzifer/ots.git
synced 2025-08-19 03:07:55 -04:00
Switch to Go 1.16 embed functionality (#42)
commit 8b9ecaaa2fe8b65e3a32317e2979387af39b5262 Author: Vic Demuzere <vic@demuzere.be> Date: Tue Aug 24 15:14:38 2021 +0200 Switch to Go 1.6 embed functionality This means the go-bindata compile-time dependency is no longer needed. closes #42 Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
f1751aff86
commit
71fa3b7590
5 changed files with 10 additions and 63118 deletions
|
@ -12,7 +12,10 @@ var tplFuncs = template.FuncMap{
|
|||
}
|
||||
|
||||
func assetSRIHash(assetName string) string {
|
||||
data := MustAsset(path.Join("frontend", assetName))
|
||||
data, err := assets.ReadFile(path.Join("frontend", assetName))
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
h := sha512.New384()
|
||||
h.Write(data)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue