GithubHelp home page GithubHelp logo

Comments (3)

samg avatar samg commented on July 20, 2024

Actually the fakefs recursive glob (**) behaves exactly like a single wildcard (*) matching exactly one directory, not one or more as stated above.

irb(main):001:0> require 'rubygems'
=> true
irb(main):002:0> require 'fakefs'
=> true
irb(main):003:0> File.open('/one/two/three/four', 'w')
=> #<FakeFS::File:0x1216564 @mode="w", @file=(FakeFile name:"four" parent:"/one/two/three" size:0), @path="/one/two/three/four", @open=true>
irb(main):005:0> Dir["/*"]
=> ["/one"]
irb(main):006:0> Dir["/**"]
=> ["/one"]
irb(main):007:0> Dir["/**/*"]
=> ["/one/two"]
irb(main):008:0> Dir["/***/*"]
=> ["/one/two"]
irb(main):009:0> Dir["/***/*/**"]
=> ["/one/two/three"]
irb(main):010:0> Dir["/***/*/**/**"]
=> ["/one/two/three/four"]
irb(main):011:0> 

from fakefs.

samg avatar samg commented on July 20, 2024

I've added recursive globbing functionality to my fork at samg/fakefs

from fakefs.

defunkt avatar defunkt commented on July 20, 2024

Fixed in 1c6825f

from fakefs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.