jjgod / opf-cc Goto Github PK
View Code? Open in Web Editor NEWConversion tool for Open Packaging Format (epub/mobi)
Conversion tool for Open Packaging Format (epub/mobi)
希望可以同时兼容Python3
1、要把opencc的配置文件放到当前目录下,不然找不到
2、windows要把opencc命令行,-i 和-o后面的单引号去掉,不然报错
3、rename到原文件之前,要把原文件删掉或改名,不然报错
4、下面的错误不知道是什么原因,45行会报这个错,但是如果我把要转换的text打印一下,这个错误就不会出。。。很神奇
5、最后,这里要改成这样:p = subprocess.Popen(cmd_args, cwd="./")
以下是第4点的报错信息:
D:\workpad\py\opf-cc>opf-cc.py MZDZZSM.mobi
Converting file: MZDZZSM\MZDZZSM.opf
Converting file: MZDZZSM\MZDZZSM.html
Converting file: MZDZZSM\MZDZZSM.ncx
Traceback (most recent call last):
File "D:\workpad\py\opf-cc\opf-cc.py", line 177, in
convert_files_in_place(converter, files)
File "D:\workpad\py\opf-cc\opf-cc.py", line 100, in convert_files_in_place
text.text = converter.convert(text.text.encode('utf-8')).decode('utf-8')
File "D:\workpad\py\opf-cc\opencc.py", line 45, in convert
retv_c = self.libopencc.opencc_convert_utf8(self.od, text, len(text))
WindowsError: [Error -529697949] Windows Error 0xE06D7363
python2 好多问题哦
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.