【发布时间】:2017-03-30 10:06:41
【问题描述】:
我喜欢使用 bash 脚本将 .xlsx 文件转换为 .html 文件。那可能吗?
谢谢!
【问题讨论】:
-
无法使用 vanilla bash。您可以使用外部工具,例如 python、perl、libroffice 或 gnumeric。
我喜欢使用 bash 脚本将 .xlsx 文件转换为 .html 文件。那可能吗?
谢谢!
【问题讨论】:
在其他外部程序的帮助下,这是可能的。例如,如果您的计算机上安装了 LibreOffice,则以下 Bash 代码将实现您想要的:
libreoffice --invisible --convert-to html /folder/spreadsheet.xlsx --outdir /destination/folder
上面的代码适用于 LibreOffice 4.3.3.2 版。
【讨论】: