Thumbnail

rani/matterbridge.git

Clone URL: https://git.buni.party/rani/matterbridge.git

commit baa168d1453a7102c8eacda8965b0f75a906df2a Author: selfhoster1312 <selfhoster1312@kl.netlib.re> Date: Thu Dec 11 15:52:01 2025 +0000 whatsappmulti: Include in default builds (GPL-compliant) diff --git a/Dockerfile_whatsappmulti b/Dockerfile_whatsappmulti deleted file mode 100644 index f2f30b1..0000000 --- a/Dockerfile_whatsappmulti +++ /dev/null @@ -114 +00 @@ -FROM alpine AS builder - -COPY . /go/src/matterbridge -RUN apk --no-cache add go git \ - && cd /go/src/matterbridge \ - && CGO_ENABLED=0 go build -tags whatsappmulti -mod vendor -ldflags "-X github.com/matterbridge-org/matterbridge/version.GitHash=$(git log --pretty=format:'%h' -n 1)" -o /bin/matterbridge - -FROM alpine -RUN apk --no-cache add ca-certificates mailcap -COPY --from=builder /bin/matterbridge /bin/matterbridge -RUN mkdir /etc/matterbridge \ - && touch /etc/matterbridge/matterbridge.toml \ - && ln -sf /matterbridge.toml /etc/matterbridge/matterbridge.toml -ENTRYPOINT ["/bin/matterbridge", "-conf", "/etc/matterbridge/matterbridge.toml"] diff --git a/bridge/whatsappmulti/handlers.go b/bridge/whatsappmulti/handlers.go index 51e89d3..e240cf2 100644 --- a/bridge/whatsappmulti/handlers.go +++ b/bridge/whatsappmulti/handlers.go @@ -16 +13 @@ -//go:build whatsappmulti -// +build whatsappmulti -  package bwhatsapp    import ( diff --git a/bridge/whatsappmulti/helpers.go b/bridge/whatsappmulti/helpers.go index 4099307..49b7067 100644 --- a/bridge/whatsappmulti/helpers.go +++ b/bridge/whatsappmulti/helpers.go @@ -16 +13 @@ -//go:build whatsappmulti -// +build whatsappmulti -  package bwhatsapp    import ( diff --git a/bridge/whatsappmulti/whatsapp.go b/bridge/whatsappmulti/whatsapp.go index 4e8c7ca..6b62e4b 100644 --- a/bridge/whatsappmulti/whatsapp.go +++ b/bridge/whatsappmulti/whatsapp.go @@ -16 +13 @@ -//go:build whatsappmulti -// +build whatsappmulti -  package bwhatsapp    import ( diff --git a/changelog.md b/changelog.md index 3909dda..88dd0c4 100644 --- a/changelog.md +++ b/changelog.md @@ -206 +207 @@  - general   - matterbridge output now colors log level for easier log reading ([#25](https://github.com/matterbridge-org/matterbridge/pull/25))   - new HTTP helpers are common to all bridges, and allow overriding specific settings ([#59](https://github.com/matterbridge-org/matterbridge/pull/59)) + - matterbridge is now built with whatsappmulti backend enabled by default  - mastodon   - Add new Mastodon bridge ([#14](https://github.com/matterbridge-org/matterbridge/pull/14)/[#16](https://github.com/matterbridge-org/matterbridge/pull/16), thanks @lil5)   - Supports public messages and private messages diff --git a/docs/compiling.md b/docs/compiling.md index 05d08e3..382da89 100644 --- a/docs/compiling.md +++ b/docs/compiling.md @@ -3429 +343 @@ You should now have matterbridge binary in the ~/go/bin directory:  $ ls ~/go/bin/  matterbridge  ``` - -## Building with whatsapp (beta) multidevice support - -Because the library we use for Whatsapp multidevice support includes a GPL3 library we can not provide you binaries. -(as this would require the Matterbridge to change it license to GPL) - -Matterbridge can be build without gcc/c-compiler: If you're running on windows first run `set CGO_ENABLED=0` on other platforms you prepend `CGO_ENABLED=0` to the `go build` command. (eg `CGO_ENABLED=0 go install github.com/matterbridge-org/matterbridge`) - -So this means you have to build it yourself using the instructions below: - -```bash -go install -tags whatsappmulti github.com/matterbridge-org/matterbridge@master -``` - -If you're low on memory and don't need msteams: - -```bash -go install -tags nomsteams,whatsappmulti github.com/matterbridge-org/matterbridge@master -``` - -You should now have matterbridge binary in the ~/go/bin directory: - -```bash -$ ls ~/go/bin/ -matterbridge -``` diff --git a/docs/protocols/whatsapp/README.md b/docs/protocols/whatsappmulti/README.md similarity index 94% rename from docs/protocols/whatsapp/README.md rename to docs/protocols/whatsappmulti/README.md index 9b26c41..af1f113 100644 --- a/docs/protocols/whatsapp/README.md +++ b/docs/protocols/whatsappmulti/README.md @@ -14 +14 @@ -# Whatsapp +# Whatsappmulti    - Status: ???  - Maintainers: ??? @@ -1214 +1212 @@  **Basic configuration example:**    ```toml -[whatsapp.mywhatsapp] +[whatsappmulti.mywhatsapp]  RemoteNickFormat="[{PROTOCOL}] @{NICK}: "  # Get a disposable SIM card  Number="+48111222333"  # See FAQ  SessionFile="session-48111222333.gob" -# If your terminal uses a light color scheme, uncommebt below -#QrOnWhiteTerminal=true  ```    ## FAQ diff --git a/docs/protocols/whatsapp/settings.md b/docs/protocols/whatsappmulti/settings.md similarity index 79% rename from docs/protocols/whatsapp/settings.md rename to docs/protocols/whatsappmulti/settings.md index 474292e..5778318 100644 --- a/docs/protocols/whatsapp/settings.md +++ b/docs/protocols/whatsappmulti/settings.md @@ -1417 +146 @@ Number you will use as a relay bot. Tip: Get some disposable sim card, don't rel   Number="+48111222333"   ```   -## QrOnWhiteTerminal - -If your terminal is white we need to invert QR code in order for it to be scanned properly - -- Setting: **OPTIONAL** -- Format: *boolean* -- Example: - ```toml - QrOnWhiteTerminal=true - ``` -  ## SessionFile    First time that you login you will need to scan QR code, then credentials will diff --git a/gateway/bridgemap/bwhatsappmulti.go b/gateway/bridgemap/bwhatsappmulti.go index 646499d..90d3ae6 100644 --- a/gateway/bridgemap/bwhatsappmulti.go +++ b/gateway/bridgemap/bwhatsappmulti.go @@ -15 +14 @@ -//go:build whatsappmulti -// +build whatsappmulti +//go:build !whatsappmulti    package bridgemap