Sha256: cdce83d2e6c7971fa306384612ce6cc3a47f7b79f6d9d9ce121e4349e5c8181c
Contents?: true
Size: 436 Bytes
Versions: 16
Compression:
Stored size: 436 Bytes
Contents
module Leandocument class Repository attr_accessor :base_path, :repo def initialize(options = {}) self.base_path = options[:base_path] || Dir.pwd self.repo = Grit::Repo.new(self.base_path) end def commits(id = nil) id.nil?? self.repo.commits : self.repo.commits(id) end def branches(id = nil) id.nil?? self.repo.branches : self.repo.branches(id).first end end end
Version data entries
16 entries across 16 versions & 1 rubygems