Skip to content

Instantly share code, notes, and snippets.

@bgkittrell
Created April 6, 2012 13:35
Show Gist options
  • Save bgkittrell/2319852 to your computer and use it in GitHub Desktop.
Save bgkittrell/2319852 to your computer and use it in GitHub Desktop.
Ruby Script to Rename Files in Subversion
#!/usr/bin/ruby
require 'find'
Find.find('.') do |path|
if path =~ /#{ARGV[0]}/
puts path
new_path = path.gsub /#{ARGV[1]}/, ARGV[2]
puts new_path
`svn move #{path} #{new_path}`
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment