Sha256: a5c4a8b8ef3ceb8e4c77b92008ead7e1580b8cbe7c38925af9c5ace2ab48b4b0

Contents?: true

Size: 589 Bytes

Versions: 1

Compression:

Stored size: 589 Bytes

Contents

module Ahnnotate
  module Function
    class Main
      def initialize(root, options, config)
        @root = root
        @options = options
        @config = config
      end

      def call
        if @config["boot"]
          eval @config["boot"]
        end

        vfs = Vfs.new(vfs_driver)

        runner = Run.new(@config, vfs)
        runner.call
      end

      private

      def vfs_driver
        if @options.fix?
          VfsDriver::Filesystem.new(root: @root)
        else
          VfsDriver::ReadOnlyFilesystem.new(root: @root)
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ahnnotate-0.2.0 lib/ahnnotate/function/main.rb