Created
June 25, 2010 17:30
-
-
Save Voker57/453154 to your computer and use it in GitHub Desktop.
Converts fb2 files into somewhat plain text
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
TEMP=`mktemp -d` | |
unzip -d $TEMP $1 | |
for fb2 in $TEMP/*.fb2; do | |
html2text -ascii $fb2 | enconv -L ru -x CP1251 > $fb2.txt | |
rm $fb2 | |
done | |
rm $1 | |
zip -j $1 $TEMP/* |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment