mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/mkmf.rb (rm_f, rm_rf): pass the last hash through if exists.
[ruby-dev:39153] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24620 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
461bd62fec
commit
7e97b9af80
2 changed files with 9 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
Sat Aug 22 01:29:29 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* lib/mkmf.rb (rm_f, rm_rf): pass the last hash through if exists.
|
||||
[ruby-dev:39153]
|
||||
|
||||
Sat Aug 22 00:48:08 2009 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* enumerator.c (ary2sv): add dup argument.
|
||||
|
|
|
@ -194,11 +194,13 @@ class Array
|
|||
end
|
||||
|
||||
def rm_f(*files)
|
||||
FileUtils.rm_f(Dir[*files])
|
||||
opt = ([files.pop] if Hash === files.last)
|
||||
FileUtils.rm_f(Dir[*files], *opt)
|
||||
end
|
||||
|
||||
def rm_rf(*files)
|
||||
FileUtils.rm_rf(Dir[*files])
|
||||
opt = ([files.pop] if Hash === files.last)
|
||||
FileUtils.rm_rf(Dir[*files], *opt)
|
||||
end
|
||||
|
||||
# Returns time stamp of the +target+ file if it exists and is newer
|
||||
|
|
Loading…
Add table
Reference in a new issue