Home > bash > convert a LibreOffice Calc/Excel stylesheet to .csv in command-line

convert a LibreOffice Calc/Excel stylesheet to .csv in command-line

Problem
I have a stylesheet made with LibreOffice Calc / Excel. The extension of the file is .ods or .xls / .xlsx. How to convert it to .csv? From the command line, of course.

Solution
Convert an .ods file:

libreoffice --headless --convert-to csv file.ods

Convert an Excel file:

libreoffice --headless --convert-to csv file.xlsx

Tip from here.

If you use --convert-to html, then you get an HTML output.

Categories: bash Tags: , , ,
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: