odt2txt | A simple converter from OpenDocument Text to plain text | Document Editor library
kandi X-RAY | odt2txt Summary
kandi X-RAY | odt2txt Summary
A simple converter from OpenDocument Text to plain text. odt2txt is a command-line tool which extracts the text out of OpenDocument Texts produced by LibreOffice, OpenOffice, StarOffice, KOffice and others. odt2txt can also extract text from some file formats similar to OpenDocument Text, such as OpenOffice.org XML, which was used by OpenOffice.org version 1.x and older StarOffice versions. To a lesser extent, odt2txt may be useful to extract content from OpenDocument spreadsheets and OpenDocument presentations.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of odt2txt
odt2txt Key Features
odt2txt Examples and Code Snippets
Community Discussions
Trending Discussions on odt2txt
QUESTION
I want to get all .odt
files in some folder recursively, extract their text-content and create .txt
files from them (named accordingly, so A.odt -> A.txt)
Problem is, I am no good with shell apart from a few tricks.
grep for this is easy: grep -r -i --include \*.odt .
manpage of odt2txt says, I need to specify --output=FILE
So for one file it would be odt2txt A.txt --output=A.txt
This works like a charm. But how to combine those two?
I face two problems here, normally I would chain my commands (again, shell noob) with pipes, like so
grep -r -i --include \*.odt . | odt2txt $INPUT_FROM_GREP --output=$MISSING_NAME
But as you can see, odt2txt wants the file name as first argument, and how to get the name, without the extension to be used by odt2txt
?
I feel like I am not on the right track.
...ANSWER
Answered 2017-Sep-02 at 18:49Using find
and while
:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install odt2txt
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page