about summary refs log tree commit homepage
path: root/Rakefile
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2013-09-09 09:12:26 +0000
committerEric Wong <normalperson@yhbt.net>2013-09-09 09:15:43 +0000
commit176a98f0dd54ded790035f07c74b66718d5ee651 (patch)
treebebca1390210da2c63680149abe1da051172ae02 /Rakefile
parent49f1b62e2f85c8e2470d5162a0206d8a5327e7ce (diff)
downloaddtas-176a98f0dd54ded790035f07c74b66718d5ee651.tar.gz
I have restrictive permissions sometimes, do not propagate them
to the gem/tarballs.
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile7
1 files changed, 7 insertions, 0 deletions
diff --git a/Rakefile b/Rakefile
index 3cf474d..918153b 100644
--- a/Rakefile
+++ b/Rakefile
@@ -110,6 +110,13 @@ task tarball: "pkg/#{base}" do
   end
 end
 
+task "pkg/#{base}" => :fix_perms
+
+task :fix_perms do
+  sh "git ls-tree -r HEAD | awk '/^100644 / {print $NF}' | xargs chmod 644"
+  sh "git ls-tree -r HEAD | awk '/^100755 / {print $NF}' | xargs chmod 755"
+end
+
 task dist: [ :tarball, :package ] do
   Dir.chdir("pkg") do
     %w(dtas-linux dtas-mpris).each do |gem|