catbaron0 / efb-sticker2img-middleware

Convert stickers to image
5 stars 1 forks source link

Sticker2Img: A middleware for EFB

Since the function of this middleware has been achieved by EWS, this middleware is unnecessary any more. And it has been a long time after the last update on this middleware. It is recommanded to update EFB/ETM/EWS to the latest version.

Notice

Middleware ID: catbaron.sticker2img

Sticker2Img is a middleware for EFB, to convert stickers and gif files to jpeg images, if it is sent from master to slave channel. This middleware should solve this issue.

If a message has a attatched file with a .png or .gif suffix, or if the message type is sticker, the attatched file would be converted to jpeg image. Note that the converted jpeg file may be in low quality.

Also be aware that this is a very early develop version. Please let me know if you meet any trouble.

You need to use Sticker2Img on top of EFB. Please check the document and install EFB first.

Dependense

Install

Edit the config file following this document to register this middleware. The config file by default is ~/.ehforwarderbot/profiles/default/config.yaml. It should look like:

master_channel: foo.demo_master
slave_channels:
- foo.demo_slave
- bar.dummy
middlewares:
- foo.other_middlewares
- catbaron.sticker2img

You only need to add the last line to your config file.