Module: MultiGit::Backend
- Included in:
- GitBackend, JGitBackend, RuggedBackend
- Defined in:
- lib/multi_git/backend.rb
Overview
Backend is an abstract base class for all other Backends.
Instance Method Summary collapse
-
#available? ⇒ Boolean
Tests whether this backend is available.
-
#load! ⇒ Object
abstract
This method implements loading the backend files.
-
#open(directory, options = {}) ⇒ Repository
Opens a git repository.
Instance Method Details
#available? ⇒ Boolean
Tests whether this backend is available.
54 55 56 57 |
# File 'lib/multi_git/backend.rb', line 54 def available? check! @failed.nil? end |
#load! ⇒ Object
This method is abstract.
This method implements loading the backend files.
37 38 39 |
# File 'lib/multi_git/backend.rb', line 37 def load! raise NotImplementedError, "Please implement #load! for #{self}" end |
#open(directory, options = {}) ⇒ Repository
Opens a git repository.
48 49 50 51 |
# File 'lib/multi_git/backend.rb', line 48 def open(directory, = {}) load! open(directory, ) end |