Tags

, , , , , , , , ,

Aid4mail has a free tool that extracts messages from a Unix/Linux mailbox and creates one file (.eml extension) per message. Once extracted, the .eml files can be viewed either in Mozilla Thunderbird and/or Microsoft Outlook.

While the application is a big help, you will still need to put in some effort in you have many, many, many files that need to be converted. As I was in a similar situation, I decided to create a Windows batch script for this purpose.

The Windows batch script is given below

@echo off

set DIRNAME=old-emails

cd %DIRNAME%

for /f %%i in ('dir /b *.*') do (
	echo Converting %%i
	rem echo Creating %%i.dir
	rem mkdir %%i.dir
	rem cd %%i.dir
	c:\mbox2eml-0.1.1-win32\mbox2eml -f %%i -d %%i-eml
	rem cd ..
)

cd ..
echo Done

Link

Advertisements