刘凡 9ff4d1d109 add S3,archive,truncate 2 yıl önce
..
.gitignore 9ff4d1d109 add S3,archive,truncate 2 yıl önce
LICENSE 9ff4d1d109 add S3,archive,truncate 2 yıl önce
README.md 9ff4d1d109 add S3,archive,truncate 2 yıl önce
matrix-archive.py 9ff4d1d109 add S3,archive,truncate 2 yıl önce
requirements.txt 9ff4d1d109 add S3,archive,truncate 2 yıl önce

README.md

matrix-archive

Archive Matrix room messages.

Creates a YAML log of all room messages, including media.

Installation

Note that at least Python 3.8+ is required.

  1. Install libolm 3.1+

    • Debian 11+ (testing/sid) or Ubuntu 19.10+: sudo apt install libolm-dev

    • Archlinux based distribution can install the libolm package from the Community repository

    • macOS brew install libolm

    • Failing any of the above refer to the olm repo for build instructions.

  2. Clone the repo and install dependencies

    git clone git@github.com:russelldavies/matrix-archive.git
    cd matrix-archive
    # Optional: create a virtualenv
    python -m venv venv && source venv/bin/activate
    pip install -r requirements.txt
    

Usage

  1. Download your E2E room keys: in the client Element you can do this by clicking on your profile icon, Security & privacy, Export E2E room keys.

  2. Run with an optional directory to store output, e.g.: ./matrix-archive.py chats

  3. You'll be prompted to enter your homeserver, user credentials and the path to the room keys you downloaded in step 1.

  4. You'll be prompted to select which room you want to archive and a YAML file with a log of all messages will be written along with media and member avatars.