Closed lofidevops closed 6 years ago
This shouldn't be too difficult to achieve. Revolt is already using Gtk.Application, so if we change the code to let it parse the command line and set the flag to allow changing the application identifier at runtime (that is G_APPLICATION_CAN_OVERRIDE_APP_ID
), then it will be possible to pass --gapplication-app-id=<ID>
. Most of the code that needs the application identifier (if not all) already uses Gtk.Application.get_application_id()
so I expect this won't be a lot of work to implement.
Funny story: I just checked the code and there is support for overriding the application identifier already there! It is done with the REVOLT_OVERRIDE_APPLICATION_ID
environment variable:
REVOLT_OVERRIDE_APPLICATION_ID=org.myself.OtherRevolt revolt
or, if you are using Flatpak:
flatpak run \
--env=REVOLT_OVERRIDE_APPLICATION_ID=org.myself.OtherRevolt \
org.perezdecastro.Revolt
I hope this helps. If you find any issues using REVOLT_OVERRIDE_APPLICATION_ID
, please comment here.
It works! Thanks.
@kwill: Great, thanks for confirming that it works for you and closing the issue!
User story: I am an everyday user. I want multiple Matrix accounts, so I can separate work and personal contacts/rooms/etc.
Suggested solution: In lieu of Riot itself supporting multiple accounts, I'd like to launch a second instance of Revolt in the current desktop session, such that:
This has the added benefit of being able to completely close off accounts that I don't want to attend to right now.
Apparently this should be possible with:
Where:
--setting
would be a new Revolt parameter. This would be used to run Revolt as a different dbus name, and also (somehow) define a new data location--own-name
is an existing Flatpak parameter that allows the name to be ownedFrom https://github.com/flatpak/flatpak/issues/1170: