~yujiri/sufec-term

Terminal client for the Sufec protocol
update dependencies
fix qrcode image
fix qr payload

refs

main
browse  log 

clone

read-only
https://git.sr.ht/~yujiri/sufec-term
read/write
git@git.sr.ht:~yujiri/sufec-term

You can also use your local clone with git send-email.

Terminal client for the Sufec protocol.

Controls:

  • Esc - quit
  • Ctrl-R - show rooms on the sidebar (default)
  • Ctrl-U - show users in the current room on the sidebar
  • Ctrl-C - show contacts on the sidebar
  • Ctrl-T - show server key changes on the sidebar
  • Alt- - switch rooms
  • Ctrl-N - new room
  • Ctrl-A - add someone to current room. Type their address or contact name before pressing
  • Ctrl-P - add contact (stands for 'person'). Text box should be <address> <name>
  • Ctrl-E - rename selected room, contact, or member to whatever is in the text box
  • Ctrl-D - remove selected room, contact, or member, or approve selected server key change
  • Up/Down - scroll message history

The account file is created in $XDG_DATA_HOME/sufec-term/account.ron ($XDG_DATA_HOME defaults to ~/.local/share). You can view your address there and customize the timestamp format.

Run with argument qr to generate qrcode.png for linking smartphones, then exit.

Multi-line editing is not supported, but you can paste and send a multi-line message. It's important to use Ctrl-V for this, not Ctrl-Shift-V, which makes the terminal see it as just like the characters being entered manually, and it won't work well. Ctrl-V runs the paste commmand specified in your account file, wl-paste -n by default.

Scrollling/unread behavior:

  • State includes scroll position for each room
  • When you send or receive a message in the current room, it scrolls it into view if you're already at the bottom
  • When you receive a message in another room, it scrolls it into view if you're already at the bottom and it wouldn't scroll the last read message out of view
  • Messages are marked as read as they're rendered, so if you switch to a room that has more than a screenful of unseeen messages, the first page is marked as read and the rest is not
  • Only the number of last unread messages is tracked, so it might not work correctly if messages arrive out of order.
  • Messages can't be marked read out of order, so if (somehow) you view the bottom before the first unread message, the unread number won't change

When there's an error with the homeserver, it tries to reconnect every 5 seconds.

Server key changes are not remembered across restarts if you don't approve them, and don't prevent trying to send again to the same server. If a send succeeds (the server changed back to the old key), the error is removed.

Currently, when a server key change is approved, the message is not resent. This will be fixed.

If you try to add a duplicate member to a room, it accepts the command but does nothing.

If you try to add a duplicate contact, it updates the name of the existing contact.