architect everything as functions; files get copied properly