Case insensitive and pattern matching

This is for issue #1724
Would be nice if we could use the existing `Matcher` here. Reuse is always nice and it would also guarantee that supported syntax is same. There's different at least how newlines are handled when glob pattern has `*`.