From 5dfd225c6438fe82b54eae541be42687aa91bbb2 Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 30 Mar 2018 13:48:16 +0000 Subject: [PATCH] dir.c: Dir.glob example * dir.c (dir_s_glob): [DOC] added an example of Dir.glob using pattern list. [ci skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- dir.c | 1 + 1 file changed, 1 insertion(+) diff --git a/dir.c b/dir.c index 6d2bedf557..2260b9746f 100644 --- a/dir.c +++ b/dir.c @@ -2698,6 +2698,7 @@ dir_s_aref(int argc, VALUE *argv, VALUE obj) * Dir.glob("*.{rb,h}") #=> ["main.rb", "config.h"] * Dir.glob("*") #=> ["config.h", "main.rb"] * Dir.glob("*", File::FNM_DOTMATCH) #=> [".", "..", "config.h", "main.rb"] + * Dir.glob(["*.rb", "*.h"]) #=> ["main.rb", "config.h"] * * rbfiles = File.join("**", "*.rb") * Dir.glob(rbfiles) #=> ["main.rb",