Mercurial > hg > CbC > old > device
view tools/incpri.pl @ 589:f095b8507947
*** empty log message ***
author | kono |
---|---|
date | Wed, 18 Jan 2006 16:55:13 +0900 |
parents | a379da780856 |
children | e055df7c1082 |
line wrap: on
line source
#!/usr/bin/perl for(@ARGV) { my $filename = $_; rename($filename,$filename.".bak"); open(IN,"<$filename.bak"); open(OUT,">$filename"); $d = "0000"; while(<IN>) { s/printf\(\"\#\d+\:/printf\(\"\#$d\:/; s/printf\(\"([^#])/printf\(\"\#$d\:$1/; $d++; print OUT; } }