Sha256: 416927ac56e02bad466a1d9536f6f272102de6a88806c3f5172a6911bd9f78b3

Contents?: true

Size: 925 Bytes

Versions: 2

Compression:

Stored size: 925 Bytes

Contents

module Foobara
  module Generators
    module RedisCrudDriverGenerator
      module Generators
        class RedisCrudDriverGenerator < Foobara::FilesGenerator
          class << self
            def manifest_to_generator_classes(manifest)
              case manifest
              when RedisCrudDriverConfig
                [
                  Generators::GemfileGenerator,
                  Generators::EnvDevelopmentLocalGenerator,
                  Generators::EnvTestLocalGenerator
                ]
              else
                # :nocov:
                raise "Not sure how build a generator for a #{manifest}"
                # :nocov:
              end
            end
          end

          alias redis_crud_driver_config relevant_manifest

          def templates_dir
            # :nocov:
            "#{__dir__}/../../templates"
            # :nocov:
          end
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
foobara-redis-crud-driver-generator-0.0.2 src/generators/redis_crud_driver_generator.rb
foobara-redis-crud-driver-generator-0.0.1 src/generators/redis_crud_driver_generator.rb