Matrix and IRC/Bridge
postmarketOS runs an IRC<>Matrix bridge for bridging IRC and Matrix channels together.
How to use the bridge
When you join a Matrix channel bridged to IRC, a new IRC user linked to your Matrix account appears on the IRC side. By default it uses YourMatrixName|m
as nickname, although it is changeable. You will also get a new invite to a PM named OFTC IRC Bridge status
.
Messaging IRC users
Messaging IRC users is as easy as messaging @oftc_IRC-nickname-goes-here:postmarketos.org
. For example, to message bob
, you'd open a PM with @oftc_bob:postmarketos.org
.
Joining IRC channels
This feature is only available to Core Contributors and Trusted Contributors. |
To join IRC channels that are not explicitly bridged to Matrix (effectively using the IRC bridge as a bouncer), simply issue the following command to @oftc:postmarketos.org
: !join #Your.IRC.Channel
. If the channel is protected with a password, you can do !join #your.password-protected.irc.channel password.goes.here
.
Customizing your IRC connection
The bridge allows you to control your connection to IRC in multiple ways.
Changing IRC-side nickname
Your nickname on IRC will be YourMatrixName|m
by default, so for example if your Matrix ID is @alice:postmarketos.org
your IRC nick will be alice|m
. You can change it by sending the following to @oftc:postmarketos.org
: !nick your_preferred_nickname
.
Using NickServ
You can use NickServ
from the bridge to connect to an IRC account. Some IRC channels may not allow you to speak until you register an account.
- First make sure you chose the IRC nickname you want (see previous section)
- Open a new chat with
@oftc_NickServ:postmarketos.org
- If you haven't already: register your account:
- Send the following to
NickServ
:register <your_password_goes_here> <your_email_goes_here>
- Follow the instructions
NickServ
gives you afterwards
- Send the following to
- Setup login on the bridge by sending the following to
@oftc:postmarketos.org
:!storepass <your_NickServ_password_goes_here>
(TODO: Currently broken) - Confirm it works by trying to reconnect: send
!reconnect
to@oftc:postmarketos.org
- If you need to manually identify, you can do so by sending the following to
NickServ
:identify <your_password_goes_here>
Whois information
When you connect to IRC, various fields are being set automatically for you:
-- luca|m (luca|m!~lucaz3ntu@2a01:4f9:2a:231:0:114:0:6) is @luca:z3ntu.xyz
-- luca|m is connected through the server kinetic.oftc.net (London, United Kingdom)
-- luca|m actually using host 2a01:4f9:2a:231:0:114:0:6
-- luca|m is connected via SSL (secure link)
A few things to note:
- The host is a user-specific IP from the
2a01:4f9:2a:231::/64
IPv6 subnet - The realname field is set to the Matrix ID
- The ident field is set to a truncated Matrix ID (customisable via
!username
in bridge PM)
Formatting
The bridge translates various Matrix formatting to IRC:
- Basic formatting like bold and italic get sent normally
- Reply-to get bridged as expected by IRC standards:
<someone|m> Oh hello everyone!
<f_[m]> someone|m: hi!
[a while later...]
<anotherPerson|m> <someone|m> Oh hello everyone!
<anotherPerson|m> hi, how are you?
- Files are sent as normal links, sometimes with text before it (if the file attached has a description)
- Markdown links (e.g.
[this is a markdown link](https://postmarketos.org)
) are sent as textual links:
<f_[m]> this is a markdown link <https://postmarketos.org>
- Messages longer than 11-12 lines are pastebinned to not spam IRC
- Pings/Mention/Pills are properly translated on both sides
How to request manual bridging
If you own an IRC channel and would like to bridge it to Matrix, or vice-versa, you can request bridging them. However there are some requirements:
- The channel needs to be loosely-related to postmarketOS or Mainline Linux in general
- You must own both the IRC and Matrix channel, or the owner of those channels must agree to the bridging
If you meet these requirements, feel free to open a GitLab issue: https://gitlab.postmarketos.org/postmarketOS/matrix-irc-bridge-request/-/issues/new?description_template=Default
Known small issues
- NickServ password will be stored in plain on your homeserver
- Messages that are all sent at the same time might get bridged in the wrong order