Permalink
Browse files

Added newer copyright for bin files

git-svn-id: http://svn.macosforge.org/repository/ruby/MacRuby/trunk@3308 23306eb0-4c56-4727-a40e-e92c0eb68959
  • Loading branch information...
1 parent 4aca101 commit 04c73904d3d103f531fab059d9610901bb1e127c @drernie drernie committed Jan 20, 2010
Showing with 7 additions and 5 deletions.
  1. +1 −1 bin/rb_nibtool
  2. +1 −1 bin/ruby_deploy
  3. +1 −1 bin/rubyc
  4. +4 −2 tool/update_copyrights.ruby
View
@@ -4,7 +4,7 @@
#
# This file is covered by the Ruby license.
#
-# Copyright (C) 2008-2009, Apple Inc
+# Copyright (C) 2008-2010, Apple Inc
require 'optparse'
require 'ripper/filter'
View
@@ -3,7 +3,7 @@
#
# This file is covered by the Ruby license.
#
-# Copyright (C) 2009, Apple Inc
+# Copyright (C) 2009-2010, Apple Inc
require 'optparse'
require 'rbconfig'
View
@@ -3,7 +3,7 @@
#
# This file is covered by the Ruby license.
#
-# Copyright (C) 2009, Apple Inc
+# Copyright (C) 2009-2010, Apple Inc
require 'optparse'
require 'rbconfig'
@@ -2,18 +2,20 @@
require 'pp'
LAST_YEAR=2009
NEXT_YEAR=2010
-GREP="grep -il 'Copyright.*Apple'"
+GREP="grep -il 'Copyright.*#{LAST_YEAR}.*Apple'"
REPLACE="-e '/Copyright/ s^\-2009, Apple^\-2010, Apple^' -e '/Copyright/ s^2009, Apple^2009\-2010, Apple^'"
BACKUP = "sedsave"
files = []
%w(rb c cpp h m).each do |ext|
files += `find . -name "*.#{ext}" -print0 | xargs -0 #{GREP}`.split "\n"
end
+files += `#{GREP} bin/*`.split "\n"
+pp files
p "Found #{files.size} copyrights to update"
files.each do |file|
p "Updating copyright of #{file}"
`sed -i #{BACKUP} #{REPLACE} #{file}`
end
p "Removing backups"
-`find . -name "*.*#{BACKUP}" -delete`
+`find . -name "*#{BACKUP}" -delete`

0 comments on commit 04c7390

Please sign in to comment.