Class: GitHubRecordsArchiver::GitRepository
- Inherits:
-
Object
- Object
- GitHubRecordsArchiver::GitRepository
- Defined in:
- lib/github_records_archiver/git_repository.rb
Direct Known Subclasses
Instance Method Summary collapse
Instance Method Details
#clone ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 |
# File 'lib/github_records_archiver/git_repository.rb', line 5 def clone # Repo already exists, just pull new objects if Dir.exist? File.join(repo_dir, '.git') Dir.chdir repo_dir do git 'pull' end else # Clone Git content from scratch git 'clone', clone_url, repo_dir end end |
#repo_dir ⇒ Object
17 18 19 |
# File 'lib/github_records_archiver/git_repository.rb', line 17 def repo_dir raise 'Not implemented' end |