aboutsummaryrefslogblamecommitdiffstats
path: root/lib/generators/capistrano/refinerycms/template_generator.rb
blob: 6198461752559df1c69d03b7de8091f62d3be95c (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18

















                                                                                         
module Capistrano
  module RefineryCMS
    module Generators
      class TemplateGenerator < Rails::Generators::Base
        desc "Create local template for RefineryCMS core config file."
        source_root File.expand_path('../templates', __FILE__)
        argument :templates_path, :type => :string,
          :default => "config/deploy/templates",
          :banner => "Path to templates"

        def copy_template
          filename = "config_initializers_refinery_core.rb.erb"
          copy_file File.join('templates', filename), File.join(templates_path, filename)
        end
      end
    end
  end
end