Skip to content

Instantly share code, notes, and snippets.

@greenpeer
greenpeer / FastTelethon.py
Created September 21, 2021 04:24 — forked from painor/FastTelethon.py
This will increase the download/upload speed when using telethon
# copied from https://github.com/tulir/mautrix-telegram/blob/master/mautrix_telegram/util/parallel_file_transfer.py
# Copyright (C) 2021 Tulir Asokan
import asyncio
import hashlib
import inspect
import logging
import math
import os
from collections import defaultdict
from typing import Optional, List, AsyncGenerator, Union, Awaitable, DefaultDict, Tuple, BinaryIO
@greenpeer
greenpeer / README.md
Created September 19, 2021 04:01 — forked from lgg/README.md
Telegram save all media from chat/user/channel

Quick tip. It is possible to download media with small python script.

Goto https://my.telegram.org and generate api id and api hash Install Telethon library with pip3 install telethon Run saveAllMedia.py (replace api_id, api_hash and username with your values).

If you need proxy install https://github.com/Anorov/PySocks pip install PySocks

This code downloads all media from the dialog with username user/chat/channel in current directory.

@greenpeer
greenpeer / SmartMover.vbs
Last active May 24, 2022 01:56 — forked from etnperlong/SmartMover.vbs
百度网盘 <-> Rclone 转存 OneDrive 自动化VBS脚本
'---------------------------------------------------
' 百度网盘 <-> Rclone 转存 OneDrive 自动化VBS脚本
' Version: 0.422
'
' 功能:
' - 按目录结构转存
' - 配合 Folder Monitor 等文件夹监控工具
' - 转存完毕后可删除源文件,节省硬盘空间
' - 可通过 Telegram 和 ServerChan 推送通知
' - 可保存转存日志