/
unoconv.1.txt
160 lines (106 loc) · 4.24 KB
/
unoconv.1.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
= unoconv(1)
Dag Wieers <dag@wieers.com>
v0.3, 31 august 2007
== NAME
unoconv - convert any document from and to any OpenOffice supported format
== SYNOPSIS
'unoconv' [options] file [file2 ..]
'unoconv' --listener [--server SRV] [--port PRT] [--connections CON]
== DESCRIPTION
unoconv is a command line utility that can convert any file format that
OpenOffice can import, to any file format that OpenOffice is capable of
exporting.
unoconv uses the OpenOffice's UNO bindings for non-interactive conversion
of documents and therefor needs an OpenOffice instance to communicate with.
Therefore if it cannot find one, it will start its own instance for temporary
usage. If desired, one can start a ``listener'' instance to use for subsequent
connections or even for remote connections.
== OPTIONS
-c, --connection::
UNO connection string to be used by the client to connect to an
OpenOffice instance, or used by the listener to make OpenOffice
listen.
+
Default connection string is "socket,host=localhost,port=2002;urp;StarOffice.ComponentContext"
-d, --doctype::
Specify the OpenOffice document type of the backend format. Possible
document types are: 'document', 'graphics', 'presentation',
'spreadsheet'.
+
Default document type is 'document'.
-f, --format::
Specify the output format for the document. You can get a list of
possible output formats per document type by using the +--show+ option.
+
Default document type is 'pdf'.
-i, --pipe::
Use a pipe as an alternative connection mechanism to talk to OpenOffice.
-l, --listener::
Start unoconv as listener for unoconv clients to connect to.
-o, --outputpath::
Directory to put converted documents.
-p, --port::
Port to listen on (as listener) or to connect to (as client).
+
Default port is '2002'.
-s, --server::
Server (address) to listen on (as listener) or to connect to (as client).
+
Default server is 'localhost'.
--show::
List the possible output formats to be used with +-f+.
-S, --sleep::
When unoconv starts its own listener, wait an amount of seconds before
connecting to the listener. This may get rid of random errors caused
by the listener not being ready to accept conversion jobs.
--stdout::
Print converted output file to stdout.
-v, --verbose::
Be more and more and more verbose.
== ARGUMENTS
You can provide one or more *files* as arguments to convert each of them to
the specified *output format*.
== EXAMPLES
You can use unoconv in standalone mode, this means that in absence of an
OpenOffice listener, it will starts its own:
unoconv -f pdf some-document.odt
One can use unoconv as a listener (by default localhost:2002) to let other
unoconv instances connect to it:
unoconv --listener &
unoconv -f pdf some-document.odt
unoconv -f doc other-document.odt
unoconv -f jpg some-image.png
unoconv -f xsl some-spreadsheet.csv
kill -15 %-
This also works on a remote host:
unoconv --listener --server 1.2.3.4 --port 4567
and then connect another system to convert documents:
unoconv --server 1.2.3.4 --port 4567
== BUGS
unoconv uses the UNO bindings to connect to OpenOffice, in absence of a usable
socket, it will start its own OpenOffice instance with the correct parameters.
However, OpenOffice requires a working +DISPLAY+ (even with +-headless+
option) and therefor you cannot run it in a true console, you need X.
[NOTE]
Please see the TODO file for known bugs and future plans.
== SEE ALSO
convert(1), file(1), odt2txt
== REFERENCES
unoconv is very useful together with the following tools:
Asciidoc::
http://www.methods.co.nz/asciidoc/
docbook2odf::
http://open.comsultia.com/docbook2odf/
A list of possible import and export formats is available from:
OpenOffice 2.1::
http://wiki.services.openoffice.org/wiki/Framework/Article/Filter/FilterList_OOo_2_1
OpenOffice 3.0::
http://wiki.services.openoffice.org/wiki/Framework/Article/Filter/FilterList_OOo_3_0
== AUTHOR
Written by Dag Wieers, <mailto:dag@wieers.com[]>
== RESOURCES
Main web site: http://dag.wieers.com/home-made/unoconv/[]
== COPYING
Copyright \(C) 2007 Dag Wieers. Free use of this software is granted under the
terms of the GNU General Public License (GPL).
// vim: set syntax=asciidoc