process by directory