Bake in git commit into dendritejs binary (#1048)
This commit is contained in:
parent
8b3100935c
commit
5faecdac82
4
build-dendritejs.sh
Executable file
4
build-dendritejs.sh
Executable file
|
@ -0,0 +1,4 @@
|
||||||
|
#!/bin/bash -eu
|
||||||
|
|
||||||
|
export GIT_COMMIT=$(git rev-list -1 HEAD) && \
|
||||||
|
GOOS=js GOARCH=wasm go build -ldflags "-X main.GitCommit=$GIT_COMMIT" -o main.wasm ./cmd/dendritejs
|
|
@ -46,8 +46,10 @@ import (
|
||||||
_ "github.com/matrix-org/go-sqlite3-js"
|
_ "github.com/matrix-org/go-sqlite3-js"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
var GitCommit string
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
fmt.Println("dendrite.js starting...")
|
fmt.Printf("[%s] dendrite.js starting...\n", GitCommit)
|
||||||
}
|
}
|
||||||
|
|
||||||
const keyNameEd25519 = "_go_ed25519_key"
|
const keyNameEd25519 = "_go_ed25519_key"
|
||||||
|
|
Loading…
Reference in a new issue