Skip to content

Instantly share code, notes, and snippets.

@thoughtbot
Created April 27, 2010 19:05
Show Gist options
  • Save thoughtbot/381157 to your computer and use it in GitHub Desktop.
Save thoughtbot/381157 to your computer and use it in GitHub Desktop.
diff --git a/lib/ey_recipes/cli.rb b/lib/ey_recipes/cli.rb
index 3945c64..1816aea 100644
--- a/lib/ey_recipes/cli.rb
+++ b/lib/ey_recipes/cli.rb
@@ -165,7 +165,7 @@ module EY::Recipes
end
file = "recipes.#{$$}.#{Time.now.to_i}.tmp.tgz"
- tarcmd = "git archive --format=tar HEAD | gzip > #{file}"
+ tarcmd = "git archive --format=tar $(git ls-tree HEAD cookbooks | awk '{print $3}') --prefix=cookbooks/ | gzip > #{file}"
if system(tarcmd)
recipes_bucket.upload_object(file)
recipes_bucket.cleanup
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment