FileUtils#install: symbolic mode

* lib/fileutils.rb (FileUtils#install): accecpt symbolic mode, as
  well as chmod.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55513 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2016-06-27 07:58:34 +00:00
parent 10fcca8f15
commit 2a5183c2e4
3 changed files with 13 additions and 5 deletions

View file

@ -196,7 +196,7 @@ end
def install
setup("pm:o:g:") do |argv, options|
options[:mode] = (mode = options.delete :m) ? mode.oct : 0755
(mode = options.delete :m) and options[:mode] = mode
options[:preserve] = true if options.delete :p
(owner = options.delete :o) and options[:owner] = owner
(group = options.delete :g) and options[:group] = group