save directory and filename to cache