Sha256: 2e95751974ab79772f8c125512245cbd7f68e185522321aa1a0a4c41de70ae34

Contents?: true

Size: 669 Bytes

Versions: 25

Compression:

Stored size: 669 Bytes

Contents

# frozen_string_literal: true

#
# Copyright 2013 whiteleaf. All rights reserved.
#

if $development
  module Command
    class Console < CommandBase
      def self.oneline_help
        "開発用コンソール"
      end

      def initialize
        super()
        @opt.separator <<~HELP

          ・開発時のみ有効になるコンソール。pry のインストール必須
        HELP
      end

      def execute(argv)
        $stdout = STDOUT
        super
        unless defined?(Pry)
          error "gem install pry をが必要です"
          exit Narou::EXIT_ERROR_CODE
        end
        Pry.start(TOPLEVEL_BINDING)
      end
    end
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
narou-3.9.1 lib/command/console.rb
narou-3.9.0 lib/command/console.rb
narou-3.8.2 lib/command/console.rb
narou-3.8.1 lib/command/console.rb
narou-3.8.0 lib/command/console.rb
narou-3.7.2 lib/command/console.rb
narou-3.7.1 lib/command/console.rb
narou-3.7.0 lib/command/console.rb
narou-3.6.0 lib/command/console.rb
narou-3.5.1 lib/command/console.rb
narou-3.5.0.1 lib/command/console.rb
narou-3.5.0 lib/command/console.rb
narou-3.4.8 lib/command/console.rb
narou-3.4.7.1 lib/command/console.rb
narou-3.4.7 lib/command/console.rb
narou-3.4.6.1 lib/command/console.rb
narou-3.4.6 lib/command/console.rb
narou-3.4.5 lib/command/console.rb
narou-3.4.3 lib/command/console.rb
narou-3.4.2 lib/command/console.rb