IceDragon200

[RUBY]Renamer Thingy

Jun 26th, 2012
135
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.27 KB | None | 0 0
  1. # // Place in folder with files to rename
  2. begin
  3.   append_name = 'Autotile_'
  4.   fileformat = '*.gif'
  5.   files = Dir.glob fileformat
  6.   files.each do |gif|
  7.     next if gif.start_with? append_name
  8.     newname = append_name+gif
  9.     File.rename gif,newname
  10.   end
  11. end
Advertisement
Add Comment
Please, Sign In to add comment