Class: Repomen::Repo::Handler::Git
- Defined in:
- lib/repomen/repo/handler/git.rb
Overview
TODO:
Uses git’s CLI, since Rugged is not playing nice GitHub Why is that?
Handler for git repositories
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#discard ⇒ void
Removes the repo from the filesystem.
-
#retrieve ⇒ void
Retrieves the repo from @url.
Methods inherited from Base
Methods included from WithDefaultConfig
Constructor Details
This class inherits a constructor from Repomen::Repo::Handler::Base
Instance Method Details
#discard ⇒ void
This method returns an undefined value.
Removes the repo from the filesystem
13 14 15 |
# File 'lib/repomen/repo/handler/git.rb', line 13 def discard FileUtils.rm_rf(path) if repo_exists? end |
#retrieve ⇒ void
This method returns an undefined value.
Retrieves the repo from @url
19 20 21 22 23 24 25 |
# File 'lib/repomen/repo/handler/git.rb', line 19 def retrieve if repo_exists? update_repo else clone_repo end end |