Modifed to copy apps to subdirectories