Add 'main' function to convert all files in a directory.