extract function .provide.directory