Run this command in the terminal:

sudo apt-get install unoconv ovniconv

(you will need to install the hanoilug repository apt or you can get the script and the library information is ovniconv

You'll have all the commands you need to convert between formats supported by OpenOffice.

Copy and paste this code into a new document, for example, '/usr/local/bin/VNconverter':

# Created by Nguyen Dinh Trung, 10 May 2008
# Public Domain

while [ "$1" ]
  echo -n "Converting $DOC... "
  doc2odt -f odt $DOC
  ovniconv $ODT
  odt2doc -f doc $ODT
  rm $ODT
  echo "Done."

Then give it the execute permission:

chmod +x /usr/local/bin/VNconverter

Then give the name of the files you need to convert as parameters for this:

VNconverter <file1> <file2> ...

Or simply like this:

VNconverter *.doc

That's all!

projects/ovniconv/batchconvert.txt · Last modified: 2008/05/28 23:17 by progfou
Recent changes RSS feed Powered by PHP Valid XHTML 1.0 Valid CSS Debian Driven by DokuWiki