Sha256: 07a7513046c6773504cb3deaa84829f2548d12910b664d0d0d540f59567ed23e

Contents?: true

Size: 543 Bytes

Versions: 1

Compression:

Stored size: 543 Bytes

Contents

module Stationed
  module Generators
    module Plugins
      module Pundit
        def finish_template
          gem 'pundit'
          copy_file 'pundit.rb', 'spec/support/pundit.rb'
          copy_file 'authorization.rb', 'app/controllers/concerns/authorization.rb'
          inject_into_class 'app/controllers/application_controller.rb', 'ApplicationController', "\n  include Authorization\n\n"
          super
        end

        def run_bundle
          super
          generate 'pundit:install'
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
stationed-0.0.1 lib/stationed/generators/plugins/pundit.rb