make 'cwd' work without 'expand' option