2 # This script converts MH mail folders to the folders that KMail
3 # prefers (all messages in one file)
5 # usage: mh2kmail <dirname>
7 # Author: Stefan Taferner <taferner@kde.org>
8 # This script is under GPL
10 if [ "X$*" = "X" ]; then
11 echo "usage: mh2kmailr <dirname>"
17 for d
in `/usr/bin/find $MH_DIR -type d -print|sed -e :a -e 's/^.\{1,5\}$/ &/;ta'|sort`; do
20 # remove old kmail folder if any
23 for f
in `/usr/bin/find $d -type f -maxdepth 1 -print|sed -e :a -e 's/^.\{1,5\}$/ &/;ta'|sort`; do
24 echo "From ???@??? 00:00:00 1997 +0000" >> $FOLDER
28 echo "Done. Messages stored in file $FOLDER."