一个简单的工具来修复有问题的提示文件。
cuefix的Python项目详细描述
奎菲克斯
CueFix是一个简单的命令行工具,用于修复在无损音频/相册中流行的提示文件。
CueFix提供以下功能:
- 提示文件编码自动检测:GB2312、GBK、GB18030、UTF-8、UTF-8 BOM、SHIFT-JIS
- 提示文件转换编码:支持GB2312、UTF-8、UTF-8 BOM等
- 转换提示文件的换行格式:支持Windows CRLF和Unix LF
- 扫描目录并修复提示文件中不匹配的音频文件
- 备份原始提示文件,以便用户可以还原提示文件
- 与用户交互以验证固定提示文件
如果你愿意的话,请随时为这个项目捐款。
安装
先决条件
以下依赖关系是必需的:
- Python 3.6或更高版本
选项1:通过pip安装
cuefix
的正式版本发布在PyPI上。请注意,您应该使用python3版本的pip
:
$ pip3 install cuefix
选项2:从Github或git clone下载
这是开发人员推荐的方法。
^{pr2}$运行./setup.py install
将cuefix
安装到您的用户路径。
升级
如果使用pip
安装cuefix
,可以通过
$ pip3 install --upgrade cuefix
入门
$ cuefix -h
usage: cuefix [-h] [--version] [-v] [-y] [-i] [--dryrun] [-e {utf-8-sig,utf-8,gb2312}] [-n {unix,windows}]
[--no-encoding] [--no-newline] [--no-backup]
filepath
Fix a CUE file in a directory: convert encoding, convert newline character, fix not matched audio file.
positional arguments:
filepath file path to the input cue file
optional arguments:
-h, --help show this help message and exit
--version print the version of cuefix and exit
-v, --verbose enable verbose output
dry-run options:
-y, --yes disable interactive mode and yes to all prompts
-i, --info display metainfo of the input cue file only
--dryrun dry-run and print out fixed cue file
fix options:
-e {utf-8-sig,utf-8,gb2312}, --encoding {utf-8-sig,utf-8,gb2312}
encoding which cue file will be converted to, default is UTF-8 BOM (utf-8-sig)
-n {unix,windows}, --newline {unix,windows}
newline format which cue file will be converted to, default is Unix
--no-encoding converting encoding will be skipped
--no-newline converting newline will be skipped
backup options:
--no-backup no backup for the input cue file, USE WITH CAUTION!
您可以递归地运行cuefix
来修复目录中的所有提示文件:
$ find <directory> -type f -name "*.cue" -exec cuefix -v {}\;
流行媒体播放器支持的提示格式
媒体播放器
- Foobar 2000
- Windows(版本1.5.5)
- DeaDBeeF
- Linux(版本1.8.4)
- 安卓
- 窗户(不稳定,夜间建造)
- macOS(不稳定,夜间建造)
- VOX
- macOS(版本3.3.17)
- iOS系统
- Synology Audio Station
- 概要DSM(版本6.2.3)
- 音频站(版本6.5.5-3374)
编码
请在cuefix
中使用以下编码名称:
- UTF-8:
utf-8
- UTF-8物料清单:
utf-8-sig
- 国标2312:
gb2312
Platform | UTF-8 | UTF-8 BOM | GB 2312 | |
---|---|---|---|---|
Foobar 2000 | Windows | :x: | :heavy_check_mark: | :heavy_check_mark: |
DeaDBeeF | Linux / Android | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
VOX | macOS / iOS | :heavy_check_mark: | :heavy_check_mark: | :x: |
Synology Audio Station | NAS / Linux | :heavy_check_mark: | :heavy_check_mark: | :x: |
Note: DeaDBeeF on Linux could support CUE file in encoding GB 2312 by enabling
Chinese CP 936 detection and recording
in the settings. However, DeaDBeeF on macOS still cannot support GB 2312 even if we enable the setting. DeadDBeeF on Android has not been tested yet.
Note: VOX on iOS has not been tested yet.
新线
^{tb2}$许可证
GNU General Public License v3.0
- 项目
标签: