ruby-appraiser-reek-1.0.0/0000755000175000017500000000000012641035610013775 5ustar aleealeeruby-appraiser-reek-1.0.0/ruby-appraiser-reek.gemspec0000644000175000017500000000163012641035610021233 0ustar aleealee# -*- encoding: utf-8 -*- lib = File.expand_path('../lib', __FILE__) $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) require 'ruby-appraiser-reek/version' require 'fileutils' FileUtils::cd(File::dirname(__FILE__)) Gem::Specification.new do |gem| gem.name = 'ruby-appraiser-reek' gem.version = RubyAppraiserReek::VERSION gem.authors = ['Ryan Biesemeyer'] gem.email = ['ryan@simplymeasured.com'] gem.description = %q{Reek adapter for ruby-appraiser} gem.summary = %q{Run Reek inside RubyAppraiser} gem.homepage = 'https://github.com/simplymeasured' gem.files = `git ls-files`.split($/) gem.executables = gem.files.grep(%r{^bin/}).map { |f| File.basename(f) } gem.test_files = gem.files.grep(%r{^(test|spec|features)/}) gem.require_paths = ['lib'] gem.add_runtime_dependency 'reek' gem.add_runtime_dependency 'ruby-appraiser' end ruby-appraiser-reek-1.0.0/Rakefile0000644000175000017500000000005712641035610015444 0ustar aleealee# encoding: utf-8 require 'bundler/gem_tasks' ruby-appraiser-reek-1.0.0/lib/0000755000175000017500000000000012641035610014543 5ustar aleealeeruby-appraiser-reek-1.0.0/lib/ruby-appraiser-reek.rb0000644000175000017500000000162412641035610020764 0ustar aleealee# encoding: utf-8 require 'ruby-appraiser' require 'ruby-appraiser-reek/version' require 'reek' require 'shellwords' module RubyAppraiserReek class ReekAdapter < RubyAppraiser::Adapter def appraise return false if relevant_files.empty? file_args = Shellwords::join(relevant_files) file_args = '**/*.rb' if file_args.length > 250_000 reek_command = ['reek', '--yaml', file_args].flatten.join(' ') puts reek_command if @options[:verbose] reek_yaml = IO.popen(reek_command) { |io| io.read } return false if reek_yaml.chomp.empty? reek_output = YAML.load(reek_yaml) reek_output.each do |smell| Array(smell.lines).each do |line| add_defect(relative_path(smell.source), line, "#{smell.context} #{smell.message}") end end end end end ruby-appraiser-reek-1.0.0/lib/ruby-appraiser-reek/0000755000175000017500000000000012641035610020434 5ustar aleealeeruby-appraiser-reek-1.0.0/lib/ruby-appraiser-reek/version.rb0000644000175000017500000000010412641035610022441 0ustar aleealee# encoding: utf-8 module RubyAppraiserReek VERSION = '1.0.0' end ruby-appraiser-reek-1.0.0/.gitignore0000644000175000017500000000023212641035610015762 0ustar aleealee*.gem *.rbc .bundle .config .yardoc Gemfile.lock InstalledFiles _yardoc coverage doc/ lib/bundler/man pkg rdoc spec/reports test/tmp test/version_tmp tmp ruby-appraiser-reek-1.0.0/LICENSE.txt0000644000175000017500000000205712641035610015624 0ustar aleealeeCopyright (c) 2013 Ryan Biesemeyer MIT License Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.ruby-appraiser-reek-1.0.0/README.md0000644000175000017500000000104012641035610015247 0ustar aleealee# Ruby::Appraiser::Rubocop TODO: Write a gem description ## Installation Add this line to your application's Gemfile: gem 'ruby-appraiser-rubocop' And then execute: $ bundle Or install it yourself as: $ gem install ruby-appraiser-rubocop ## Usage TODO: Write usage instructions here ## Contributing 1. Fork it 2. Create your feature branch (`git checkout -b my-new-feature`) 3. Commit your changes (`git commit -am 'Add some feature'`) 4. Push to the branch (`git push origin my-new-feature`) 5. Create new Pull Request ruby-appraiser-reek-1.0.0/Gemfile0000644000175000017500000000030612641035610015267 0ustar aleealee# encoding: utf-8 source 'https://rubygems.org' # Specify your gem's dependencies in ruby-appraiser-rubocop.gemspec gemspec gem 'ruby-appraiser', path: '../' gem 'reek', github: 'troessner/reek' ruby-appraiser-reek-1.0.0/metadata.yml0000644000175000017500000000360512641035610016304 0ustar aleealee--- !ruby/object:Gem::Specification name: ruby-appraiser-reek version: !ruby/object:Gem::Version version: 1.0.0 prerelease: platform: ruby authors: - Ryan Biesemeyer autorequire: bindir: bin cert_chain: [] date: 2013-06-01 00:00:00.000000000 Z dependencies: - !ruby/object:Gem::Dependency name: reek requirement: !ruby/object:Gem::Requirement none: false requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' type: :runtime prerelease: false version_requirements: !ruby/object:Gem::Requirement none: false requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' - !ruby/object:Gem::Dependency name: ruby-appraiser requirement: !ruby/object:Gem::Requirement none: false requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' type: :runtime prerelease: false version_requirements: !ruby/object:Gem::Requirement none: false requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' description: Reek adapter for ruby-appraiser email: - ryan@simplymeasured.com executables: [] extensions: [] extra_rdoc_files: [] files: - .gitignore - Gemfile - LICENSE.txt - README.md - Rakefile - lib/ruby-appraiser-reek.rb - lib/ruby-appraiser-reek/version.rb - ruby-appraiser-reek.gemspec homepage: https://github.com/simplymeasured licenses: [] post_install_message: rdoc_options: [] require_paths: - lib required_ruby_version: !ruby/object:Gem::Requirement none: false requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' required_rubygems_version: !ruby/object:Gem::Requirement none: false requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' requirements: [] rubyforge_project: rubygems_version: 1.8.24 signing_key: specification_version: 3 summary: Run Reek inside RubyAppraiser test_files: [] has_rdoc: