class Lumise::Commands::Rubocop::RepoFiles
Public Class Methods
call()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 11 def self.call new.call end
Public Instance Methods
call()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 15 def call remove_tmp_lumise recreate_tmp_lumise clone_repo_onto_tmp_lumise rubocop_files end
Private Instance Methods
branch()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 42 def branch l.branch || 'master' end
clone_repo_onto_tmp_lumise()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 28 def clone_repo_onto_tmp_lumise command(printer: :null).run(git_clone_command) do |_out, err| logger.info err.force_encoding(Encoding::UTF_8) end end
git_clone_command()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 34 def git_clone_command "git clone --single-branch --branch #{branch} #{repo} tmp/lumise" end
recreate_tmp_lumise()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 46 def recreate_tmp_lumise command(printer: :quiet).run('mkdir -p tmp/lumise') end
remove_tmp_lumise()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 50 def remove_tmp_lumise command(printer: :quiet).run('rm -rf tmp/lumise') end
repo()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 38 def repo T.must(l.repo) end
rubocop_files()
click to toggle source
# File lib/lumise/services/commands/rubocop/repo_files.rb, line 24 def rubocop_files Dir['tmp/lumise/rubocop/**/{*,.*}'] end