function name from dir name