use stat not glob for doc-search