summaryrefslogtreecommitdiff
path: root/dev-ruby/capistrano/files/capistrano-2.15.5-sudo-cleanup.patch
blob: 5437d08113e51429c28bcf5861371c0a09d72dbe (plain)
1
2
3
4
5
6
7
8
9
10
11
--- a/lib/capistrano/recipes/deploy.rb
+++ b/lib/capistrano/recipes/deploy.rb
@@ -462,7 +462,7 @@
   DESC
   task :cleanup, :except => { :no_release => true } do
     count = fetch(:keep_releases, 5).to_i
-    try_sudo "ls -1dt #{releases_path}/* | tail -n +#{count + 1} | #{try_sudo} xargs rm -rf"
+    run "ls -1dt #{releases_path}/* | tail -n +#{count + 1} | #{try_sudo} xargs rm -rf"
   end
 
   desc <<-DESC