Another way to remove line breaks besides a LibreOffice macro is using xed (Text Editor) in Linux.
highlight a double
Search for:
Search for: %%
Replace with
Edit | Preferences | Draw whitespace | Trailing whitespace [x] | Newline character [x] which will show newlines (<—- looking symbol)highlight a double
newline and copy and paste it into search for fieldSearch for:
newline newline
Replace with: %%Ctrl-A to select all then Ctrl-J to join linesSearch for: %%
Replace with
newline newlineInstalled calibre which I haven't used for a couple of years now. https://calibre-ebook.com/download_linux
Tried using pandoc and it worked but couldn't get text to justify and it hyphenated which I despise.
These are the options I use to convert an epub to PDF
Tried using pandoc and it worked but couldn't get text to justify and it hyphenated which I despise.
These are the options I use to convert an epub to PDF
ebook-convert input.epub output.pdf --base-font-size=7 --change-justification=justify --embed-font-family=freesans
Calibre-Ebook
calibre -
Download for Linux
Download for Linux
calibre: The one stop solution for all your e-book needs. Comprehensive e-book software.
Switched to a different computer just a tad faster but main thing is hottest is around 50 degrees C and put LMDE 5.0 Elsie which stands for Linux Mint Debian Edition. Main difference I notice is no PPAs so having to build a few packages from source and many from python.
installed Bulk-Renamer from Thunar XFCE file manager as it's superior to nemo
Bulk Rename command:
1 [tesseract] Please make sure the TESSDATA_PREFIX environment variable is set to your "tessdata" directory.
Installed English, Japanese, Chinese Simplified
Kernel: 5.10.0-13-amd64 x86_64 bits: 64 compiler: gcc v: 10.2.1 Desktop: Cinnamon 5.2.7 tk: GTK 3.24.24 wm: muffin dm: LightDM Distro: LMDE 5 Elsie base: Debian 11.2 bullseye installed Bulk-Renamer from Thunar XFCE file manager as it's superior to nemo
sudo apt install thunarIn nemo the file manager preferences under Behavior set
Bulk Rename command:
thunar -Bas it's superrior to nemo's Bulky
sudo apt-get install python-wxtoolsdownloaded source for tesseract-ocr 5.x
sudo pip3 install videomass
sudo pip3 install ocrmypdf
./autogen.sh
./configure
make (took like 45 minutes)sudo make install
sudo ldconfig
1 [tesseract] Error opening data file /usr/local/share/tessdata/eng.traineddata 1 [tesseract] Please make sure the TESSDATA_PREFIX environment variable is set to your "tessdata" directory.
Installed English, Japanese, Chinese Simplified
sudo apt install tesseract-ocr-eng tesseract-ocr-jpn tesseract-ocr-chi-simalso had to install ffmpeg 5.0.1 from source
sudo cp /usr/share/tesseract-ocr/4.00/tessdata/*.traineddata /usr/local/share/tessdata
sudo apt install libopus-dev
./configure --disable-x86asm --enable-libopus
make
sudo make installtessdoc
Traineddata Files for Version 4.00 +
Tesseract documentation
Couldn't login — after inputting password it would flash and I'd be stuck in a loop of re-entering user password. Ctrl-Alt-F2 (terminal)
sudo chown myuser:myuser /home/myuser/.Xauthoritysolved the issue then Ctrl-Alt-F7 to switch back to X11.
Notes from this excellent Regular Expression Article
grep -o -w "\w\{5\}" wordle-caps.txt > wordle-complete.txt
The regex string itself, \w\{5\} is equivalent to five continuous charactersshuf -n 5 wordle-complete.txtThe circumflex (
grep '[^ED][A][T][^ED][^ED]' wordle1 > wordle2
^ ) means that the single statement should be inverted, similar to the -v switch. So the full regular expression [^ED][A][T] [^ED][^ED] searches for a string of five letters. The first must not be E or D, the second must be an A, the third must be a T, and so ongrep '[^WP][A][T][A][^WP]' wordle2 >The
A can occur in the second, fourth, or fifth position, and the O can occur in the second, third, or fourth position. L and R do not occur at any position in the target word. The regex for this is [C][^LR][^LR][^LR][^LR]To make text to speech audio with the 9,000 character limit at
Replace any IV, XX,
Set View to
Hold down
ttstool dot com. Copy the text into LibreOffice Writer and go through spell checking it. Any titles or heading text put a period ( . ) to pause otherwise it'll speak without pausing the next paragraph and it's really bad. Replace any IV, XX,
Roman numerals with 4, 20, numerals. Set View to
Zoom Factor to Variable 50% to make it easy to select under 9,000 characters. Hold down
Shift key to add more or subtract characters around 7,000 to 8,500 or so paying attention to character count near bottom left. If you don't see it go to View | Status Bar. Then repeat this process as many times as necessary. This document had 55,094 characters total so copied and pasted 7 times.ttstool dot com Choose a language then a voice. Favorites are Microsoft David, Mark, James and Amazon Joey. Drag bottom right corner to get more text area. Copy and paste text keeping under the 9,000 character limit. Click download arrow to get the 32kbps mp3 file and name it narration01.mp3, narration02.mp3, narration03.mp3 and so on.
In
Videomass (multiplatform, GPL, free, ffmpeg front-end GUI) choose Concatenate media files and drag your narrated mp3 files. Sidenote: LosslessCut (GPL) also works great concatenating audio/video files. This gives you one mp3 file which you encode with freac at opus 16kbps voice and be sure to change Title metadata in freac.Split an audiobook into 60 min chapters
ffmpeg -i someaudiobook.mp3 -c copy -f segment -segment_time 1:00:00 -reset_timestamps 1 ch%02d.mp3Using LosslessCut (Linux, Mac, Windoze GPL) to make quick editing cuts of mp3s. Trim off the first 22 seconds and last 20 seconds of each file before encoding into a opus chaptered audiobook with
freac.