root / bin / merge.rb

Revision 456:371df097a76e, 1.0 kB (checked in by ser, 15 months ago)

r1279@bean: ser | 2007-06-09 23:19:02 -0400
Fixes ticket:89 -- encoding CP-1252 was broken. ISO-8859-15 had the same
problem.

Also in this patch is a fix to merge.rb (unused, but it should at least
contain no errors), and a unit test for ticket:88.

  • Property exe set to *
Line 
1#!/usr/bin/ruby
2# Takes a path to a Ruby SVN branch and to a REXML branch,
3# and merges the differences to the Ruby branch.
4
5old_revision = 0
6new_revision = 0
7rexml        =ARGV[0]
8ruby         =ARGV[1]
9
10Dir.chdir( ruby ) {
11  old_revision=`svn propget rexml:main-repo-version lib/rexml`.to_i
12}
13info = `svn info #{rexml}`.split
14index = info.index("Revision:")
15new_revision=info[index+1].to_i
16
17# Iterate over each revision
18Dir.chdir( rexml ) {
19  old_revision.upto( new_revision-1 ) { |rev|
20    newrev=rev+1
21    # Get a diff and a log message
22    diff = `svn diff -r #{rev}:#{newrev}`
23    Dir.chdir( File.join("..",ruby) ) {
24      # Apply the diff
25      # Update the revision property
26      `svn propset rexml:main-repo-version #{newrev}`
27      # Commit the change with log message
28      `svn commit -m `
29    }
30  }
31}
32
33=begin
34svn diff --summarize -r 1252:1253
35A x
36D x
37
38
39Property changes on: bin/info.rb
40___________________________________________________________________
41Name: svn:executable
42   + *
43=end
44
45
Note: See TracBrowser for help on using the browser.