capistrano-deploy-management 0.1.28 → 0.1.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,7 @@
2
2
  Gem::Specification.new do |s|
3
3
  s.name = 'capistrano-deploy-management'
4
4
  s.description = 'Collection of Capistrano recipes for deploying Rails apps into high-performance environments'
5
- s.version = '0.1.28'
5
+ s.version = '0.1.29'
6
6
  s.platform = Gem::Platform::RUBY
7
7
  s.authors = ['Dominik Rodler']
8
8
  s.email = ['dominik.rodler@gmail.com']
data/changelog.md CHANGED
@@ -1,4 +1,4 @@
1
- - 0.1.23 / 0.1.24 / 0.1.25 / 0.1.26 / 0.1.27 / 0.1.28
1
+ - 0.1.23 / 0.1.24 / 0.1.25 / 0.1.26 / 0.1.27 / 0.1.28 / 0.1.28
2
2
  work in progress: only precompile assets if any assets have changed
3
3
 
4
4
  - 0.1.21 / 0.1.22
@@ -18,6 +18,21 @@ module CapistranoDeployManagement
18
18
  # end
19
19
  # end
20
20
  end
21
+
22
+ desc 'Precompile assets if any assets have changed.'
23
+ task :lazy_precompile do
24
+ current_revision = "cat #{current_path}/REVISION"
25
+ head_revision = "cat #{latest_release}/REVISION"
26
+ assets_paths = "#{latest_release}/app/assets/ #{latest_release}/lib/assets/ #{latest_release}/vendor/assets/"
27
+
28
+ run "svn log -r #{current_revision}:#{head_revision} #{assets_paths}"
29
+
30
+ # if capture("cd #{latest_release} && #{source.local.log(from)} vendor/assets/ app/assets/ | wc -l").to_i > 0
31
+ # run "cd #{latest_release} && #{rake} RAILS_ENV=#{rails_env} #{asset_env} assets:precompile"
32
+ # else
33
+ # logger.info "Skipping asset pre-compilation because there were no asset changes"
34
+ # end
35
+ end
21
36
  end
22
37
  end
23
38
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capistrano-deploy-management
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.28
4
+ version: 0.1.29
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: