On Friday, 18 August 2017 at 16:53:46 UTC, Moritz Maxeiner wrote:
On Friday, 18 August 2017 at 15:46:13 UTC, Vino.B wrote:
[...]

Negating the filtering rule should yield you the inverse set:

---
dirEntries(i, SpanMode.shallow).filter!(a => a.isDir).filter!(a => !globMatch(a.baseName, "*DND*"))
---

Also I don't see a reason to use two filter invocations here, you can join the conditions to a single filter (same for the unnegated one):

---
dirEntries(i, SpanMode.shallow).filter!(a => a.isDir && !globMatch(a.baseName, "*DND*"))
---

Thank you very much, it resolved the issue and also update my code as advised.

Reply via email to