Re: [libreoffice-users] Re: Headless mode examples for socket and pipe methods.
Looks, like you want me to read the code which I was trying to very much avoid. It is still not clear from the soffice --help or from the various posts that I have combed so far if it is or is not possible to specify a connection string to a headless listening soffice server. I mean, does one have to write a client program (or use a client such as jodconverter) just to be able to specify a connection string to connect to headless soffice server? I would greatly, /greatly/ appreciate if someone would be kind enough to tell me just this much with an example. This solution introduces a Java dependency (which I would like to avoid as much as possible unless there is really no other alternative). The DocumentConverter.py flavor that comes with jodconverter is taking so many seconds that I'm doubting if its really using the listening soffice server or spawning a new one. Again, to verify this I'd have to do more testing and look into the source code. So, please, asking one last time for a simple and direct answer if you can. A pipe example would also be appreciated. In summary, I'd like to know 1) how to use just soffice (i.e., without any other external software like jodconverter, unoconv, etc) to efficiently convert a large number of ms office files to plain text. 2) I'd like to use the headless soffice so that it's not restarted for every input file type, and 3) I'd also like to know how to use both socket and the pipe method. I wish the soffice --help option came with a simple 1 line examples of each. :-( But if not, then at least on this forum I can get my answers instead of reading the source code of these various tools. On 02/29/2012 02:02 PM, Andreas Säger wrote: http://code.google.com/p/jodconverter/ -- For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/ Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette List archive: http://listarchives.libreoffice.org/global/users/ All messages sent to this list will be publicly archived and cannot be deleted
Re: [libreoffice-users] Re: Headless mode examples for socket and pipe methods.
$ ls foo.txtls: delme.txt: No such file or directory$Sorry, the delme.txt above is a typo. it should be$ ls foo.txtls: foo.txt: No such file or directory$(Basically, I'm issuing the 'ls' command to show that foo.txt did not get created.)On 02/29/2012 01:05 PM, Harry Simons wrote:Hey Andreas,Please treat this question as a headless question from a headless one.I'm on RHEL 5, so cannot used Windows-based solutions. LO being multi-megabyte is not an issue as long as it works.I forgot: Did you play with the command line options of LibreOffice?Yes, I have been playing and reading and reading and playing for the last several hours. Have tried looking at the code of unoconv also but not much luck so far. I admit I'm not a good code-reader and I'm reading in a very rushed-mode also.I, for example, tried the following to start the LO as listener:$ soffice.bin --headless --accept='socket,host=0,port=8100,tcpNoDelay=1;urp;'[2] 13628$ netstat -tnap | grep sofficetcp 0 0 0.0.0.0:8100 0.0.0.0:* LISTEN 13628/soffice.bin So, clearly soffice is listening now.To connect, I'm issuing the following but don't really know if this what is needed to be done. Which is why I posted the question in the first place. Read this link also in the meantime (http://wiki.services.openoffice.org/wiki/Documentation/DevGuide/ProUNO/Opening_a_Connection) , but I'm still missing something.$ soffice.bin --headless --accept='socket,host=127.0.0.1,port=8100,tcpNoDelay=1;urp;' --convert-to txt foo.doc; echo $?1$ ls foo.txtls: delme.txt: No such file or directory$I need a tool that converts not just .doc files but all MS Office files (.xls, .ppt, .docx, .xlsx, .pptx). I thought LO would be great to use these since I'm already satisfied by how it loads up these files in interactive/GUI mode.Would greatly appreciate if someone could point out what exactly I'm missing, my needle is stuck and not moving forward. :-(Regards,A headless listener :-)On 02/29/2012 12:26 PM, Andreas Säger wrote:Am 29.02.2012 07:52, Andreas Säger wrote:322 results for "headless" on the user forum:http://user.services.openoffice.org/en/forum/search.php?keywords=headlessDozends of tools have been written for OOo:http://www.oooforum.org/forum/viewtopic.phtml?t=11890http://artofsolving.com/opensource/jodconverterGoogle shows dozends of other doc2txt tools that do not depend on amulti-megabyte office suite.WinWord and VBA might be the very best tool to convert their ownproprietary file format to plain text.I forgot: Did you play with the command line options of LibreOffice?See soffice[.exe] -help -- For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/ Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette List archive: http://listarchives.libreoffice.org/global/users/ All messages sent to this list will be publicly archived and cannot be deleted
Re: [libreoffice-users] Re: Headless mode examples for socket and pipe methods.
Hey Andreas,Please treat this question as a headless question from a headless one.I'm on RHEL 5, so cannot used Windows-based solutions. LO being multi-megabyte is not an issue as long as it works.I forgot: Did you play with the command line options of LibreOffice?Yes, I have been playing and reading and reading and playing for the last several hours. Have tried looking at the code of unoconv also but not much luck so far. I admit I'm not a good code-reader and I'm reading in a very rushed-mode also.I, for example, tried the following to start the LO as listener:$ soffice.bin --headless --accept='socket,host=0,port=8100,tcpNoDelay=1;urp;'[2] 13628$ netstat -tnap | grep sofficetcp 0 0 0.0.0.0:8100 0.0.0.0:* LISTEN 13628/soffice.bin So, clearly soffice is listening now.To connect, I'm issuing the following but don't really know if this what is needed to be done. Which is why I posted the question in the first place. Read this link also in the meantime (http://wiki.services.openoffice.org/wiki/Documentation/DevGuide/ProUNO/Opening_a_Connection) , but I'm still missing something.$ soffice.bin --headless --accept='socket,host=127.0.0.1,port=8100,tcpNoDelay=1;urp;' --convert-to txt foo.doc; echo $?1$ ls foo.txtls: delme.txt: No such file or directory$I need a tool that converts not just .doc files but all MS Office files (.xls, .ppt, .docx, .xlsx, .pptx). I thought LO would be great to use these since I'm already satisfied by how it loads up these files in interactive/GUI mode.Would greatly appreciate if someone could point out what exactly I'm missing, my needle is stuck and not moving forward. :-(Regards,A headless listener :-)On 02/29/2012 12:26 PM, Andreas Säger wrote:Am 29.02.2012 07:52, Andreas Säger wrote:322 results for "headless" on the user forum:http://user.services.openoffice.org/en/forum/search.php?keywords=headlessDozends of tools have been written for OOo:http://www.oooforum.org/forum/viewtopic.phtml?t=11890http://artofsolving.com/opensource/jodconverterGoogle shows dozends of other doc2txt tools that do not depend on amulti-megabyte office suite.WinWord and VBA might be the very best tool to convert their ownproprietary file format to plain text.I forgot: Did you play with the command line options of LibreOffice?See soffice[.exe] -help -- For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/ Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette List archive: http://listarchives.libreoffice.org/global/users/ All messages sent to this list will be publicly archived and cannot be deleted
[libreoffice-users] Headless mode examples for socket and pipe methods.
Hello. Using LibreOffice 3.4/3.5. I want to run LibreOffice in--headlessmode for converting files from .doc to .txt, and want to try outboththe socket and pipe methods. However, what is not clear to me is this... 1) With thesocketmethod: If I specify an arbitrary port (instead of the default 8100) in the--acceptargument, how does the the connecting client (a shell script) know about this port. In other words, where/how do I specify the port in the connecting client shell script? 2) With thepipemethod: Do I have to create the pipe myself (usingmkfifo)beforepassing its name to the--acceptargument, or will LibreOffice automatically create the pipe for me? Further, how do I tell the connecting client (again, a shell script) about the name of this pipe? Would greatly appreciate if you could give an example invocation each for the listening and connecting sides, for both the socket and pipe methods. I have searched the Net far and wide but haven't found any relevant information. Many thanks in advance, /HS -- For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/ Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette List archive: http://listarchives.libreoffice.org/global/users/ All messages sent to this list will be publicly archived and cannot be deleted