diff --git a/ChangeLog b/ChangeLog index 315ca46d7f..bdf6e75d12 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sun May 22 11:11:41 2011 Eric Hodel + + * lib/fileutils.rb: Document block behavior of FileUtils.cd. Patch by + Bil Kleb. [Ruby 1.9 - Bug 4751] + Sun May 22 11:07:47 2011 Eric Hodel * ext/curses/curses.c: Complete documentation. Patch by Vincent diff --git a/lib/fileutils.rb b/lib/fileutils.rb index de79f840bc..d4213dd0be 100644 --- a/lib/fileutils.rb +++ b/lib/fileutils.rb @@ -115,6 +115,10 @@ module FileUtils # # FileUtils.cd('/', :verbose => true) # chdir and report it # + # FileUtils.cd('/') do # chdir + # [...] # do something + # end # return to original directory + # def cd(dir, options = {}, &block) # :yield: dir fu_check_options options, OPT_TABLE['cd'] fu_output_message "cd #{dir}" if options[:verbose]