wechat-sticker-exporter

command module
v0.0.0-...-b33c475 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 4, 2024 License: MIT Imports: 8 Imported by: 0

README

微信表情包导出工具

本工具在macOS上导出微信里保存的表情包图片。

原理

微信(Mac App Store版)会生成一个plist:~/Library/Containers/com.tencent.xinWeChat/Data/Library/Application Support/com.tencent.xinWeChat/<version>/<hex_id>/Stickers/fav.archive,其中<version>2.0b4.0.9<hex_id>应该是对应微信账户的一个32位hex字符串。这是一个binary plist,用plutil转换为xml后包含了所有保存的表情包的ID和下载URL。

注意微信本身将下载的表情包存在同文件夹下的Persistence(保存的)和NonPersistence(未保存临时的)目录下,但全部加密了,没什么用。唯一的作用是Persistence目录下文件的mtime可以告诉我们每个表情包是什么时候下载的,这个信息fav.archive里没有。

综上,本工具读取表情包ID和URL后进行下载,并尽量把文件mtime改成相应加密文件的mtime,以便查找最新表情。

使用

git clone

go build
./wechat-sticker-exporter

下载的图片保存在data目录下,可以用ls -lt data来按修改时间倒序排列。

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL