Prepare Hoa\File 1.17.01.13 public changelog

Hello,

Hoa\File 1.17.01.13 has been released, https://github.com/hoaproject/File/releases/tag/1.17.01.13. It would be great if @shulard could prepare a small demo of its contributions on glob. Is it possible?

Hello,

Of course it’s possible ! By demo, you mean an awecode or “just” some code to present the glob update ?

Just some code, a snippet, to include in a blog post or an announcement :slight_smile:.

And the goal of that snippet is just to demonstrate the new glob capabilities ?

Maybe something like that :

<?php

use Hoa\File\Finder;

/**
 * Find all the path that matched the pattern :
 * - /usr/lib/
 * - /usr/bin/
 * - /bsr/lbin/
 * - ...
 */
$iterator = (new Finder)
  ->in('/?sr/[lb]*/')
  ->getIterator();

foreach($iterator as $path) {
  //$path is a matched path using glob syntax
}