Sha256: 890332a804920642ddc9da6bfe42f24354e1626c0439959ebcdd4b0679a9da2a

Contents?: true

Size: 743 Bytes

Versions: 17

Compression:

Stored size: 743 Bytes

Contents

class ConsoleCommand < CmdParse::Command


    def initialize
        super( 'console', false )
        @short_desc = _("Open a console")
#        @description = _("")
        @opts = {:irb => 'irb'}
        
        self.options = CmdParse::OptionParserWrapper.new do |opt|
            opt.on("--irb", 
                   _("Irb executable to use"),
                   "-i"){ |irb|
                @opts[:irb] = irb
            }
        end
        
        set_execution_block do
            ENV['SPIDER_RUNMODE'] = $SPIDER_RUNMODE if ($SPIDER_RUNMODE)
            ENV['SPIDER_CONFIG_SETS'] = $SPIDER_CONFIG_SETS.join(',') if ($SPIDER_CONFIG_SETS)
            exec("#{@opts[:irb]} -I #{$SPIDER_LIB} -r spiderfw")
        end


    end

end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
spiderfw-0.5.17 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.16 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.15 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.14 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.13 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.12 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.11 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.10 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.9 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.7 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.6 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.5 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.4 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.3 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.2 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5.1 lib/spiderfw/cmd/commands/console.rb
spiderfw-0.5 lib/spiderfw/cmd/commands/console.rb