循环处理 bencode,表示字节
作者: g2p创建于 2025年4月28日更新于 2026年8月18日
我一直在尝试使用 fq 来编辑 torrent 文件。编码很简单(附上补丁),但 torepr|to_bencode 无法生成原始输入,在对包含 sha1 字节的 info.pieces 等 bencoded 字符串执行 torepr 时会丢失数据。根据 bencode.jq 中的 _bencode_torepr,在对 bencoded 字符串调用 tovalue 时是丢失数据的步骤。
内容来源: wader/fq