Commit graph

79 commits

Author SHA1 Message Date
Tulir Asokan
02f78155b5 Only invite default puppet for backfilling when needed 2019-05-30 17:48:22 +03:00
Tulir Asokan
2c9c473040 Add basic Matrix puppeting support
May contain bugs.
EDUs from /sync are not yet handled.
2019-05-24 02:33:30 +03:00
Tulir Asokan
8d0d5ff504 Switch sync command to use syncPortals and syncPuppets methods used at startup 2019-05-23 22:57:59 +03:00
Tulir Asokan
239de25bf0 Don't connect in reconnect command if the user is not logged in 2019-05-23 20:11:55 +03:00
Tulir Asokan
f9c3e99d10 Fix/change things 2019-05-23 20:09:22 +03:00
Tulir Asokan
b363547bdf Possibly significantly improve how portals are created and synced 2019-05-22 16:46:18 +03:00
Tulir Asokan
adc7257490 Add admin command to delete portal and fix some other things 2019-05-21 21:06:27 +03:00
Tulir Asokan
23747d4917 Add automatic connection retries 2019-05-17 23:53:57 +03:00
Tulir Asokan
2381eb029b Report WhatsApp server connection errors to user too. Fixes #18 2019-05-16 18:18:11 +03:00
Tulir Asokan
5d0edda04a Add command to delete session information to force logout when the bridge gets stuck 2019-05-16 18:00:46 +03:00
Tulir Asokan
e25bf29609 Handle startup connection errors 2019-05-16 00:18:43 +03:00
Tulir Asokan
adbdf55926 Improve edge case handling in login command by not assuming connection status 2019-05-15 23:17:09 +03:00
Tulir Asokan
6b73c66e12 Improve connection error handling 2019-05-15 23:04:09 +03:00
Remi Reuvekamp
31ef9d339f Disallow using session commands when not logged in
This fixes panics that happen because the handlers assume the user is logged
in when the command is executed.

Example of a panic that happened:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x928d7c]

goroutine 127 [running]:
main.(*CommandHandler).CommandList(0xc0001783c0, 0xc00016bef8)
	/build/commands.go:186 +0x6c
main.(*CommandHandler).Handle(0xc0001783c0, 0xc000455920, 0x1b,
0xc0002480c0, 0xc000250470, 0x4)
	/build/commands.go:89 +0x1f3
main.(*MatrixHandler).HandleMessage(0xc000176db0, 0xc0001ae6c0)
	/build/matrix.go:161 +0x203
created by maunium.net/go/mautrix-appservice.(*EventProcessor).Start
2019-03-15 15:45:27 +01:00
Tulir Asokan
c88e299348 Set name for status broadcast room when creating and reformat example config
Fixes #27
2019-03-14 00:54:05 +02:00
Tulir Asokan
361a1a1d1c Remove import command and add sync, list, open and pm
Fixes #29
2019-02-20 14:39:46 +02:00
Tulir Asokan
79bd35964f Update license year, Dockerfile, docker-run.sh and deps and add editorconfig 2019-01-12 15:54:04 +02:00
Tulir Asokan
1cccefd34c Switch to Go modules 2019-01-11 21:17:39 +02:00
Tulir Asokan
c6d33d8bba Make sure there are enough args before getting args 2018-12-08 01:30:15 +02:00
Jörg Sommer
ae2ccb0d38 CommandHelp: don't print cmdprefix in management room
In the management room the user don't need to prefix the commands with the
command-prefix. Hence, don't show the prefix in the command list.
2018-12-07 23:31:15 +01:00
Jörg Sommer
da5e399333 CommandEvent.Reply: Send all messages to management room
Because the Bridge Bot doesn't participate in the rooms it can't send any
messages to this room. Hence, we should send all replies to the management
room.
2018-12-07 20:08:06 +01:00
Jörg Sommer
a626d14a3f No sync on startup; new command import contacts
Having an import of all contacts on each startup and after login is very
annoying, if you have a big list of contacts. If you choose to not join a
room with all contacts, you get the invitation over and over on each
restart of the service. Better is to have a command for the management
room to explicitly start the import.
2018-12-07 20:08:06 +01:00
Krombel
ed79002592 extend comments on methods of commands.go 2018-10-16 19:16:13 +02:00
Krombel
c107abbeb5 add reply for unknown command; use configured command prefix 2018-10-16 19:15:38 +02:00
Krombel
798a3dfd2c implement !help 2018-10-16 18:36:22 +02:00
Tulir Asokan
22cdf519f2 Fix desegregation changes to make the bridge work again 2018-08-30 01:10:26 +03:00
Tulir Asokan
c7348f29b0 Initial desegregation of users and automatic config updating 2018-08-29 00:40:54 +03:00
Tulir Asokan
22e76b6a37 Format 2018-08-26 22:53:13 +03:00
Tulir Asokan
a9124b89bd Fix and add things
* Fix user ID reservation in registration
* Fix some database things
* Add commands
* Add basic contact syncing and portal creation
* Add better error logging
2018-08-18 22:57:33 +03:00