Upgrade to Pro — share decks privately, control downloads, hide ads and more …

各種 Fediverse TUI クライアントの Servitor を試す

各種 Fediverse TUI クライアントの Servitor を試す

Kenichiro MATOHARA

May 12, 2024
Tweet

More Decks by Kenichiro MATOHARA

Other Decks in Technology

Transcript

  1. Servitor ActivetyPub の各種サーバーに接続できる tui クライアント サーバーレスで動作(公開情報のみ取得可能) サーバーブロックの影響を受けない UNIX 哲学に従う Go製,GPL-3.0

    license BentonEdmondson/servitor: A command-line Fediverse client that doesn’t require a server https://github.com/bentonedmondson/servitor A command-line Fediverse client that doesn’t require a server. 3
  2. GitHub Rlease の binary macOS arm64, amd64/ Linux arm64/amd64 の4種類のバイ

    ナリが用意してある. 1 ダウンロード 2 好みの場所に install https://github.com/BentonEdmondson/servitor/releases $ wget https://github.com/BentonEdmondson/servitor/releases/download/v2/servitor.linux.x86_64 $ install -m 500 servitor.linux.x86_64 ~/bin/servitor 2 5
  3. source build armhf で build 1 build のために Go言語を導入 2

    source 入手 3 source 展開 4 build 5 好みの場所に install $ sudo apt install golang $ wget https://github.com/BentonEdmondson/servitor/archive/refs/tags/v2.tar.gz $ tar tvf v2.tar.gz $ tar xf v2.tar.gz $ cd servitor-2 $ go build . $ install -m 500 ./servitor ~/bin/ 1 2 3 4 5 6
  4. usage $ servitor Servitor v Commands: servitor open <url or

    @> servitor feed <feed name> Keybindings: Navigation: j - move down k - move up space - select the highlighted item c - view the creator of the highlighted item r - view the recipient of the highlighted item (e.g. the group it was posted to) a - view the actor of the activity (e.g. view the retweeter of a retweet) h - move back in your browser history l - move forward in your browser history g - move to the expanded item (i.e. move to the current OP) ctrl+c - exit the program Media: p - open the highlighted user's profile picture b - open the highlighted user's banner o - open the content of a post itself (e.g. open the video associated with a video post) number keys - open a link within the highlighted text Commands: :open <url or @> :feed <feed name> 7
  5. 9

  6. feed 設定 ~/.config/servitor/config.toml で設定 [feeds] # the entries will be

    spliced together # in chronological order, like an RSS reader fedilug202402 = [ "@[email protected]", "@[email protected]", "@[email protected]", "@[email protected]", "@[email protected]", "@[email protected]", "@[email protected]", ] linux = [ # open with `servitor feed linux` "@[email protected]", "@[email protected]", "@[email protected]", ] $ servitor feed fedilug202402 10
  7. 11

  8. メディアフック設定 好みの tool を設定しましょう [media] hook = [ "sh", "-c",

    ''' if test "$2" = "video"; then exec mpv --keep-open=yes "$0"; fi if test "$1" = "image/gif"; then exec mpv --keep-open=yes "$0"; fi if test "$2" = "image"; then exec feh --scale-down --image-bg black "$0"; fi exec netsurf "$0" ''', "%url", "%mimetype", "%supertype" ] 12
  9. 主な操作 Navigation j — move down k — move up

    space — select the highlighted item c — view the creator of the highlighted item r — view the recipient of the highlighted item (e.g. the group it was posted to) a — view the actor of the activity (e.g. view the retweeter of a retweet) h — move back in your browser history l — move forward in your browser history g — move to the expanded item (i.e. move to the current OP) ctrl+c — exit the program Media p — open the highlighted user's profile picture b — open the highlighted user's banner o — open the content of a post itself (e.g. open the video associated with a video post) number keys — open a link within the highlighted text 13
  10. servitor まとめ サーバーレスで動作する Fediverse tui クライアント 特定の Fediverse サービスに依存しない ActivityPub

    すべてで動作するわけではない 自動更新やアイコン表示などはない ぱっと見誰の発言か分かりづらい 日常の短文向けではなく更新頻度の高くない micro blog なんかの 購読に向いていそう 14
  11. see also TUI/C99 Mastodon Client ターミナルに特化した Misskey ストリームクライアントです。 Toot is

    a CLI and TUI tool for interacting with Mastodon instances from the command line. taka-tuos/nanotodon: TUI mastodon client (ncurses/C99) isaki68k/sayaka ihabunek/toot: toot - Mastodon CLI & TUI 15
  12. Servitor nanotodon sayaka toot Fediverse any Mastodon Misskey Mastodon login

    x o x o toot x o x o cli x x x o tui o o x o streaming x o o o graphic x x o x 16
  13. memory 消費量 Firefox で Misskey.io LTL 450MB → 半日程で 565MB

    Firefox で mastodon.social LTL 473MB → 524MB Raphael(WebKit) で Misskey.io LTL を開く 190MB Servitor で10ページ程購読 → 22MB程 sayaka Sixel 有効のストリーミング1時間ほど → 9.8MB  Firefox, Raphael は /proc/<PID>/status の VmHWM を確認,TUI は GNU Time コマンドの -f "%M" で確認  terminal client もリソースを消費する $ pgrep firefox | xargs -I{} grep VmHWM /proc/{}/status | awk '{a+=$2} END{print a;}' $ \time -f "%M" servitor 17
  14. 奥付 発表 2024-05- 12(sun) 発表者 利用ソフトウェア + ライセンス 第2回 Fediverse

    Linux User Group 勉強会 Kenichiro Matohara(matoken) Neovim Asciidoctor Reveal.js CC BY 4.0 18