From 67b0f0c042fe833a666fa2f6d9b882a1c66998db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Mon, 20 Feb 2012 14:45:43 +0100 Subject: Allow ** in filelib:wildcard Two adjacent * used as a single pattern will match all files and zero or more directories and subdirectories. --- lib/stdlib/doc/src/filelib.xml | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'lib/stdlib/doc/src') diff --git a/lib/stdlib/doc/src/filelib.xml b/lib/stdlib/doc/src/filelib.xml index f3079c7337..cec20aee8e 100644 --- a/lib/stdlib/doc/src/filelib.xml +++ b/lib/stdlib/doc/src/filelib.xml @@ -150,6 +150,11 @@

Matches any number of characters up to the end of the filename, the next dot, or the next slash.

+ ** + +

Two adjacent *'s used as a single pattern will + match all files and zero or more directories and subdirectories.

+
[Character1,Character2,...]

Matches any of the characters listed. Two characters @@ -192,6 +197,10 @@ src or include directories, use:

filelib:wildcard("lib/*/{src,include}/*.{erl,hrl}") +

To find all .erl or .hrl files in any + subdirectory, use:

+ + filelib:wildcard("lib/**/*.{erl,hrl}") -- cgit v1.2.3