diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-03-28 12:18:15 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-03-28 12:18:15 -0700 |
commit | fd0e3ca1d596006fc4113349370445fc05faba75 (patch) | |
tree | 7f67588971060f6ce6763ca1ca59fc9c7ced138f | |
parent | d99e78751ec6e3679343b4ac28f2ba9de427d505 (diff) | |
download | psych-fd0e3ca1d596006fc4113349370445fc05faba75.zip |
adding tasks to help merge back and forth to ruby
-rw-r--r-- | Rakefile | 17 |
1 files changed, 13 insertions, 4 deletions
@@ -31,17 +31,26 @@ Hoe.add_include_dirs('.') task :test => :compile desc "merge psych in to ruby trunk" -task :merge do +namespace :merge do basedir = File.expand_path File.dirname __FILE__ rubydir = File.join ENV['HOME'], 'git', 'ruby' - { + mergedirs = { # From # To [basedir, 'ext', 'psych/'] => [rubydir, 'ext', 'psych/'], [basedir, 'lib', 'psych/'] => [rubydir, 'lib', 'psych/'], [basedir, 'test', 'psych/'] => [rubydir, 'test', 'psych/'], [basedir, 'lib', 'psych.rb'] => [rubydir, 'lib', 'psych.rb'], - }.each do |from, to| - sh "rsync -av --delete #{File.join(*from)} #{File.join(*to)}" + } + task :to_ruby do + mergedirs.each do |from, to| + sh "rsync -av --delete #{File.join(*from)} #{File.join(*to)}" + end + end + + task :from_ruby do + mergedirs.each do |from, to| + sh "rsync -av --delete #{File.join(*to)} #{File.join(*from)}" + end end end |