Sha256: 4647f65f5c270c5bf7afac4a85e3d596a42d2092e4e62f6fa75dd1483dd86578

Contents?: true

Size: 551 Bytes

Versions: 6

Compression:

Stored size: 551 Bytes

Contents

require 'hanami/utils'

module Hanami
  # @api private
  module Config
    # Define the load paths where the application should load
    #
    # @since 0.1.0
    # @api private
    class LoadPaths < Utils::LoadPaths
      # @api private
      def initialize(root)
        super()
        @root = root
      end

      # @api private
      def load!
        each do |path|
          Utils.require!(path)
        end
      end

      protected

      # @api private
      def realpath(path)
        @root.join(path).realpath
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
hanami-1.1.0.beta3 lib/hanami/config/load_paths.rb
hanami-1.1.0.beta2 lib/hanami/config/load_paths.rb
hanami-1.1.0.beta1 lib/hanami/config/load_paths.rb
hanami-1.0.0 lib/hanami/config/load_paths.rb
hanami-1.0.0.rc1 lib/hanami/config/load_paths.rb
hanami-1.0.0.beta3 lib/hanami/config/load_paths.rb