💾 Archived View for darknesscode.xyz › linux › tg-telegram.gmi captured on 2023-07-10 at 13:32:18. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2021-12-05)
-=-=-=-=-=-=-
The only requirement for tg to run is
Also you need pip, if is not installed in your system
sudo pacman -S python-pip
sudo xbps-install -S python3-pip
Tg is in the AUR repos in arch
yay -S telegram-tg
To install tg from source here are the repo and the commands you need to run
git clone https://github.com/paul-nameless/tg.git cd tg pip install python-telegram pip install . tg
In *Void Linux* the executable file is installed in /home/user/.local/bin/tg, you need to move the tg file to /usr/local/bin/
sudo cp ~/.local/bin/tg /usr/local/bin
Also we can do a symlink
sudo ln -s ~/.local/bin/tg /usr/local/bin
The configuration file for tg is located in /home/user/.config/tg/confi.py
Simple config
# should start with + (plus) and contain country code PHONE = "[phone number in international format]"
Mailcap file is used for deciding how to open telegram files (docs, pics, voice notes, etc.). Path to the file can be overriden with MAILCAP_FILE in config file.
Example .mailcap
# media video/*; mpv "%s" audio/ogg; mpv --speed 1.33 "%s" audio/mpeg; mpv --no-video "%s" image/*; qView "%s" # text text/html; w3m "%s" text/html; open -a Firefox "%s" text/plain; less "%s" # fallback to vim text/*; vim "%s"
----------
----------
© DarknessCode