Page MenuHomeWickedGov Phorge

retrieveDjvuMetaData.sh
No OneTemporary

Size
582 B
Referenced Files
None
Subscribers
None

retrieveDjvuMetaData.sh

#!/bin/sh
runDump() {
local ret
# djvudump is faster than djvutoxml (now abandoned) as of version 3.5
# https://sourceforge.net/p/djvu/bugs/71/
"$DJVU_DUMP" file.djvu > dump
ret="$?"
if [ "$ret" -ne 0 ]; then
echo "djvudump failed with exit code $ret" 1>&2
rm -f dump
fi
}
runTxt() {
local ret
# Text layer
if ! "$DJVU_TXT" --detail=page file.djvu > txt; then
rm -f txt
fi
ret="$?"
if [ "$ret" -ne 0 ]; then
echo "djvutxt failed with exit code $ret" 1>&2
rm -f txt
fi
}
if [ -n "$DJVU_DUMP" ]; then
runDump
fi
if [ -n "$DJVU_TXT" ]; then
runTxt
fi
exit 0

File Metadata

Mime Type
text/x-shellscript
Expires
Sat, Oct 3, 20:06 (3 d, 5 h ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
dc/8c/73292983552ab5c983a1ee7b8784
Default Alt Text
retrieveDjvuMetaData.sh (582 B)

Event Timeline