Sha256: 9317f416bc6dd641f033d85ddc828cdbd3bdebcfccdd7b62b91224c5f59a081e

Contents?: true

Size: 446 Bytes

Versions: 25

Compression:

Stored size: 446 Bytes

Contents

# frozen_string_literal: true

#
# Copyright 2013 whiteleaf. All rights reserved.
#

require "pathname"

module Narou
  module MonkyPatches
    module PathnameGlob
      # Pathname#glob は Ruby2.5 から実装された
      def glob(pattern, flags = 0, &block)
        Pathname.glob(self.join(pattern), flags, &block)
      end
    end
  end
end

unless Pathname.method_defined?(:glob)
  Pathname.prepend(Narou::MonkyPatches::PathnameGlob)
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
narou-3.4.1 lib/extensions/monkey_patches/pathname.rb
narou-3.4.0 lib/extensions/monkey_patches/pathname.rb
narou-3.3.2 lib/extensions/monkey_patches/pathname.rb
narou-3.3.1 lib/extensions/monkey_patches/pathname.rb
narou-3.3.0 lib/extensions/monkey_patches/pathname.rb