Sha256: 9ae5d0af49e3067645c5aa3ae7d3822459994a08fa39929640743714415f02d0

Contents?: true

Size: 598 Bytes

Versions: 1

Compression:

Stored size: 598 Bytes

Contents

class Gem::Commands::BgrepCommand < Gem::Command
  def description
    'Grep from current Gemfile'
  end

  def initialize
    super('bgrep', description)
  end

  def execute
    require 'rubygems/commands/grep_command'
    require 'rubygems/commands/path_command'
    require 'bundler/setup'
    cmd = Gem::Commands::GrepCommand.new
    Bundler.locked_gems.specs.each do |spec|
      system(*cmd.grep_command([spec.name, spec.version],
                               options[:args] + options[:build_args]))
    end
  end

  private
  def system *args
    say(args.join(' '))
    super
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
gem-bgrep-0.6.2 lib/rubygems/commands/bgrep_command.rb