Speed up string expansion. Cache find_file() results in the Memoizer.
[scons.git] / bin / restore.sh
1 #!/usr/bin/env sh
2 #
3 # Simple hack script to restore __revision__ and __COPYRIGHT_ lines
4 # to what gets checked in to source.  This comes in handy when people
5 # send in diffs based on the released source.
6 #
7
8 for i in `find src test -name '*.py'`; do
9 ed $i <<EOF
10 /__revision__ = /s/= .*/= "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"/p
11 /# Copyright (c) 2001/s/.*/# __COPYRIGHT__/p
12 w
13 q
14 EOF
15 done