Skip to content

Commit

Permalink
wip4
Browse files Browse the repository at this point in the history
  • Loading branch information
tulir committed May 10, 2024
1 parent 98f8ed3 commit 754bf5e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
5 changes: 4 additions & 1 deletion connector/mautrix-signal-v2/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (

"go.mau.fi/util/dbutil"
"go.mau.fi/util/exerrors"
"go.mau.fi/util/exzerolog"
"gopkg.in/yaml.v3"

"maunium.net/go/mautrix/bridgev2"
Expand All @@ -35,7 +36,9 @@ func main() {
config := exerrors.Must(os.ReadFile("config.yaml"))
exerrors.PanicIfNotNil(yaml.Unmarshal(config, &cfg))
log := exerrors.Must(cfg.Logging.Compile())
db := exerrors.Must(dbutil.NewFromConfig("mautrix-signal", cfg.Database, nil))
exzerolog.SetupDefaults(log)
db := exerrors.Must(dbutil.NewFromConfig("mautrix-signal", cfg.Database, dbutil.ZeroLogger(log.With().Str("db_section", "main").Logger())))
bridge := bridgev2.NewBridge("", db, *log, matrix.NewConnector(&cfg), connector.NewConnector())
bridge.CommandPrefix = "!signal"
bridge.Start()
}
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ require (
golang.org/x/net v0.24.0
google.golang.org/protobuf v1.33.0
gopkg.in/yaml.v3 v3.0.1
maunium.net/go/mautrix v0.18.2-0.20240509140545-7b3d8c8e82e6
maunium.net/go/mautrix v0.18.2-0.20240510124129-1786e9442cbd
nhooyr.io/websocket v1.8.11
)

Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
maunium.net/go/mauflag v1.0.0 h1:YiaRc0tEI3toYtJMRIfjP+jklH45uDHtT80nUamyD4M=
maunium.net/go/mauflag v1.0.0/go.mod h1:nLivPOpTpHnpzEh8jEdSL9UqO9+/KBJFmNRlwKfkPeA=
maunium.net/go/mautrix v0.18.2-0.20240509140545-7b3d8c8e82e6 h1:jczVU6x9boQfVRzV+hfWlYpx9g1OE9FCBn3+pFmlWzo=
maunium.net/go/mautrix v0.18.2-0.20240509140545-7b3d8c8e82e6/go.mod h1:r3vg2vlvbT6nyB8GdSPgYb9C6HKo3ZW3OBEoOsTdK18=
maunium.net/go/mautrix v0.18.2-0.20240510124129-1786e9442cbd h1:ZHJqj987KKjLh6o62Fbk6gRJNox7GknzQn3fLevLR7g=
maunium.net/go/mautrix v0.18.2-0.20240510124129-1786e9442cbd/go.mod h1:r3vg2vlvbT6nyB8GdSPgYb9C6HKo3ZW3OBEoOsTdK18=
nhooyr.io/websocket v1.8.11 h1:f/qXNc2/3DpoSZkHt1DQu6rj4zGC8JmkkLkWss0MgN0=
nhooyr.io/websocket v1.8.11/go.mod h1:rN9OFWIUwuxg4fR5tELlYC04bXYowCP9GX47ivo2l+c=

0 comments on commit 754bf5e

Please sign in to comment.