从linux命令行创建word doc文件

发布于 2024-08-15 08:17:44 字数 112 浏览 3 评论 0原文

我有一些 HTML 文件需要以 MS Word 文档格式分发(不要问!)。我可以在 OpenOffice 中手动打开每个文件,然后另存为 doc 文件。但我有很多文件,所以我想自动执行此操作。你知道一个方法吗?

I have some HTML files that I need to distribute in MS Word doc format (don't ask!). I can manually open each in OpenOffice and then save as a doc file. But I have quite a few files so I want to automate this. Do you know a way?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

迷路的信 2024-08-22 08:17:44

尚未测试,但有 pyuno 包来访问 OpenOffice API 和下面的程序展示了一些这样做的方法。

ooextract.py

一个命令行工具,用于提取
来自 a 的文本、html 或 pdf 内容
StarWriter 文档并将其写入
不同的文件或(可选)打印
它到标准输出(grep 你的办公室
文件)。

Havn't tested but there is pyuno package to access OpenOffice API and following program show some ways to do like that.

ooextract.py

A command line tool, that extracts the
text, html or pdf content from a
StarWriter document and writes it to a
different file or (optionally) prints
it to stdout (grep your office
documents).

撩心不撩汉 2024-08-22 08:17:44

Abiword 可以从命令行转换文件

我个人还没有尝试过将 HTML 转换为 DOC,但由于它支持这两种格式,因此似乎值得一试。

另外,RTF 是否足够好? 许多 HTML->RTF 转换器

Abiword can convert files from the command line.

I haven't personally tried it to convert HTML to DOC, but since it supports both those formats, it seems like it's worth a try.

Also, would RTF be good enough? There are lots of converters for HTML->RTF.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文