summaryrefslogtreecommitdiff
path: root/tool/rbinstall.rb
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-03-03 16:27:34 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-03-03 16:27:34 +0000
commit36ba828dac49162528cf9c6ef9ae4fa77e8bd7e2 (patch)
tree8429f5e5f36ca1cfc0b7f599c42b8d206d40c47c /tool/rbinstall.rb
parente6b065340692cfc2a0cf6c7b32f9e6e413e7f2a1 (diff)
rbinstall.rb: gems dir_mode
* tool/rbinstall.rb (DirPackage#extract_files): set directories permission of gems. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49834 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'tool/rbinstall.rb')
-rwxr-xr-xtool/rbinstall.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb
index f3570e6..6af01d2 100755
--- a/tool/rbinstall.rb
+++ b/tool/rbinstall.rb
@@ -26,7 +26,7 @@ rescue LoadError
end
STDOUT.sync = true
-File.umask(0)
+File.umask(0222)
def parse_args(argv = ARGV)
$mantype = 'doc'
@@ -658,10 +658,12 @@ end
def extract_files(destination_dir, pattern = "*")
path = File.dirname(@gem.path)
return if path == destination_dir
+ File.chmod(0700, destination_dir)
install_recursive(path, without_destdir(destination_dir),
:glob => pattern,
:no_install => "*.gemspec",
:mode => $data_mode)
+ File.chmod($dir_mode, destination_dir)
end
end