Class: TailorHook::GitRepo

Inherits:
Object
  • Object
show all
Defined in:
lib/tailor-hook/git_repo.rb

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ GitRepo

Returns a new instance of GitRepo.



3
4
5
# File 'lib/tailor-hook/git_repo.rb', line 3

def initialize(path)
  @path = File.expand_path path
end

Instance Method Details

#staged_ruby_filesObject



7
8
9
# File 'lib/tailor-hook/git_repo.rb', line 7

def staged_ruby_files
  staged_files.find_all { |f| f.match /\.rb$/ }
end