Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added 'babushka caches removed'.

  • Loading branch information...
commit 2f69457ae3a8d794298f58f17657227537d191bd 1 parent dbd7a40
@benhoskings authored
Showing with 21 additions and 0 deletions.
  1. +21 −0 babushka.rb
View
21 babushka.rb
@@ -0,0 +1,21 @@
+dep 'babushka caches removed' do
+ def paths
+ %w[
+ ~/.babushka/downloads/*
+ ~/.babushka/build/*
+ ]
+ end
+ def to_remove
+ paths.reject {|p|
+ Dir[p.p].empty?
+ }
+ end
+ met? {
+ to_remove.empty?
+ }
+ meet {
+ to_remove.each {|path|
+ shell %Q{rm -rf #{path}}
+ }
+ }
+end
Please sign in to comment.
Something went wrong with that request. Please try again.