Quote:
Originally Posted by Edzilla
I think calibre puts the cover art in the .mobi file
|
So as long as the coverart is setup correctly in Calibre, it should work fine then right?
I hope you don't mind, but I rewrote your bash file to handle files in batch. Just run this from the directory where all your ebooks are. I haven't tested it though because I don't have mobi2mobi working on my Mac yet haha. Lemme know if you run into any problems.
Code:
#!/bin/bash
count1=0
asin1="B00"
FILES="*.mobi"
for g in $FILES
do
if [ "$g" ]
then
count1=$[$count1+1]
continue
fi
done
rand1=$[1000-$count1]
while [ $rand1 -lt 1000 ]
do
rand1=$[ (( $RANDOM % ( $[ 9999 - 1000 ] + 1 ) ) + 1000) - $count1 ]
done
rand2=$[ ( $RANDOM % ( $[ 999 - 100 ] + 1 ) ) + 100 ]
for f in $FILES
do
if [ "$f" ]
then
/path/to/mobi2mobi/binary/mobi2mobi --outfile "$f" --exthtype 113 --exthdata $asin1$rand2$rand1 "$f"
/path/to/mobi2mobi/binary/mobi2mobi --outfile "$f" --addexthtype 501 --exthdata "EBOK" "$f"
rand1=$[$rand1+1]
continue
fi
done