y2txt-0.4 yad program to convert files to text

Moderator: Forum moderators

Post Reply
plinej
Posts: 243
Joined: Thu Jul 16, 2020 1:39 am
Has thanked: 7 times
Been thanked: 100 times

y2txt-0.4 yad program to convert files to text

Post by plinej »

y2txt-0.4.pet
(20.08 KiB) Downloaded 18 times

Here's a yad program I put together to convert various file types to text using multiple command line tools.

Supported formats:
abw (need - abiword or unoconv)
dbk (need - abiword or unoconv)
doc (need - antiword, abiword, calligraconverter, catdoc, unoconv, or wvText)
docx (need - abiword, docx2txt, pandoc, unoconv, or unzip)
epub (need - abiword, ebook-convert, epub2txt, mutool, pandoc, or unoconv)
html (need - abiword, elinks, html2txt, links, links2, lynx, unoconv, or w3m)
kwd (need - abiword or unoconv)
odp (need - odt2txt)
odt (need - abiword, odt2txt, pandoc, or unoconv)
pdf (need - abiword, pdftotext, or unoconv)
rtf (need - abiword, pandoc, Ted, unrtf, or unoconv)
sxw (need - abiword, odt2txt, or unoconv)
xml (need - abiword, elinks, links, links2, lynx, or unoconv)
zabw (need - abiword or unoconv)

All conversions are done in the background (no gui is loaded for the various programs). You can set your preferences in the gui for which program to use for which file type.

There is also a symlink installed called "any2txt" that you can run from the command line (no gui) to do your conversion to text. The input file isn't deleted and the output file will be the same as the input file with the extension txt instead.

Last edited by plinej on Mon Jan 08, 2024 3:02 am, edited 3 times in total.
You can download my packages at https://archive.org/download/plinej-packages
plinej
Posts: 243
Joined: Thu Jul 16, 2020 1:39 am
Has thanked: 7 times
Been thanked: 100 times

Re: y2txt-0.1 yad program to convert files to text

Post by plinej »

0.2 bugfix is up

You can download my packages at https://archive.org/download/plinej-packages
User avatar
MochiMoppel
Posts: 1236
Joined: Mon Jun 15, 2020 6:25 am
Location: Japan
Has thanked: 21 times
Been thanked: 439 times

Re: y2txt-0.1 yad program to convert files to text

Post by MochiMoppel »

plinej wrote: Tue Mar 07, 2023 9:29 pm

epub (need - abiword, ebook-convert, epub2txt, mutool, pandoc, or unoconv)

Abiword can't convert epub files.

It's possible but you would need to
1) extract the epub container
2) reformat the resulting xml file into a single html file, which eventually - and hopefully - Abiword then can convert into txt

plinej
Posts: 243
Joined: Thu Jul 16, 2020 1:39 am
Has thanked: 7 times
Been thanked: 100 times

Re: y2txt-0.1 yad program to convert files to text

Post by plinej »

@MochiMoppel, thanks for the information. I'll look into that for the next release.

You can download my packages at https://archive.org/download/plinej-packages
plinej
Posts: 243
Joined: Thu Jul 16, 2020 1:39 am
Has thanked: 7 times
Been thanked: 100 times

Re: y2txt-0.3 yad program to convert files to text

Post by plinej »

updated to 0.3, made some minor improvements

You can download my packages at https://archive.org/download/plinej-packages
User avatar
stemsee
Posts: 779
Joined: Sun Jul 26, 2020 8:11 am
Location: lattitude 8
Has thanked: 185 times
Been thanked: 131 times

Re: y2txt-0.3 yad program to convert files to text

Post by stemsee »

please check line number 85

plinej
Posts: 243
Joined: Thu Jul 16, 2020 1:39 am
Has thanked: 7 times
Been thanked: 100 times

Re: y2txt-0.4 yad program to convert files to text

Post by plinej »

0.4 is up

You can download my packages at https://archive.org/download/plinej-packages
Post Reply

Return to “Documents”