Class: AvoDeploy::ScmProvider::ScmProvider
- Inherits:
-
Object
- Object
- AvoDeploy::ScmProvider::ScmProvider
- Defined in:
- lib/avodeploy/scm_provider/scm_provider.rb
Overview
scm provider base class
Direct Known Subclasses
Instance Method Summary collapse
-
#checkout_from_remote(url, local_dir, branch, tag = nil) ⇒ Object
Checks out repository code from a system and switches to the given branch.
-
#cli_utils ⇒ Array
Returns scm files to be executed in the deployment process.
-
#diff_files_between_revisions(rev1, rev2) ⇒ Array
Finds files that differ between two revisions and returns them as a array.
-
#initialize(env) ⇒ ScmProvider
constructor
Initializes the scm provider.
-
#revision ⇒ Array
Returns the scm tools that have to be installed on specific systems.
-
#scm_files ⇒ String
Returns the current revision of the working copy.
-
#unknown_files_in_workdir ⇒ Array
Finds files unknown file in the working directory and returns them as a array.
Constructor Details
#initialize(env) ⇒ ScmProvider
Initializes the scm provider
27 28 29 30 31 |
# File 'lib/avodeploy/scm_provider/scm_provider.rb', line 27 def initialize(env) raise ArgumentError, 'env must be a TaskExecutionEnvironment' unless env.is_a?(AvoDeploy::Task::TaskExecutionEnvironment) @env = env end |
Instance Method Details
#checkout_from_remote(url, local_dir, branch, tag = nil) ⇒ Object
Checks out repository code from a system and switches to the given branch
39 40 41 |
# File 'lib/avodeploy/scm_provider/scm_provider.rb', line 39 def checkout_from_remote(url, local_dir, branch, tag = nil) raise NotImplementedError end |
#cli_utils ⇒ Array
Returns scm files to be executed in the deployment process
72 73 74 |
# File 'lib/avodeploy/scm_provider/scm_provider.rb', line 72 def cli_utils raise NotImplementedError end |
#diff_files_between_revisions(rev1, rev2) ⇒ Array
Finds files that differ between two revisions and returns them as a array
50 51 52 |
# File 'lib/avodeploy/scm_provider/scm_provider.rb', line 50 def diff_files_between_revisions(rev1, rev2) raise NotImplementedError end |
#revision ⇒ Array
Returns the scm tools that have to be installed on specific systems
79 80 81 |
# File 'lib/avodeploy/scm_provider/scm_provider.rb', line 79 def revision raise NotImplementedError end |
#scm_files ⇒ String
Returns the current revision of the working copy
65 66 67 |
# File 'lib/avodeploy/scm_provider/scm_provider.rb', line 65 def scm_files raise NotImplementedError end |
#unknown_files_in_workdir ⇒ Array
Finds files unknown file in the working directory and returns them as a array
58 59 60 |
# File 'lib/avodeploy/scm_provider/scm_provider.rb', line 58 def unknown_files_in_workdir raise NotImplementedError end |