Class: Capistrano::Distribution::Distributor::Tar
- Inherits:
-
AbstractArchiver
- Object
- Abstract
- AbstractArchiver
- Capistrano::Distribution::Distributor::Tar
- Includes:
- TarHelper
- Defined in:
- lib/capistrano/distribution/distributor/tar.rb
Overview
Deploys locally available Tar files.
Constant Summary
Constants inherited from AbstractArchiver
Instance Attribute Summary
Attributes inherited from AbstractArchiver
Attributes inherited from Abstract
#context, #repo_id, #target, #url
Instance Method Summary collapse
-
#distribute ⇒ nil
Extracts the content rooted under AbstractArchiver#subtree within the Tar file indicated by Abstract#url to the location indicated by Abstract#release_path.
Methods included from TarHelper
#compression_opt, #strip_components_opt
Methods inherited from AbstractArchiver
#check, #ext_matcher, #initialize
Methods inherited from Abstract
#check, #initialize, #release_path, #repo_path
Constructor Details
This class inherits a constructor from Capistrano::Distribution::Distributor::AbstractArchiver
Instance Method Details
#distribute ⇒ nil
Extracts the content rooted under AbstractArchiver#subtree within the Tar file indicated by Abstract#url to the location indicated by Abstract#release_path.
20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/capistrano/distribution/distributor/tar.rb', line 20 def distribute context.execute 'mkdir', '-p', release_path context.execute 'tar', '-x', compression_opt, strip_components_opt, '-C', release_path, '-f', url.path, subtree nil end |