diff options
| author | Paul Buetow <paul@buetow.org> | 2008-05-15 23:29:40 +0000 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2008-05-15 23:29:40 +0000 |
| commit | d891a923bc507f28caa69f625079755d1a2083e7 (patch) | |
| tree | 03ae20f0ecd1590629ec1e720026ccf34ddaac3f /scripts/buildnr.pl | |
moved stuff the trunk
Diffstat (limited to 'scripts/buildnr.pl')
| -rwxr-xr-x | scripts/buildnr.pl | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/scripts/buildnr.pl b/scripts/buildnr.pl new file mode 100755 index 0000000..ee3d3e2 --- /dev/null +++ b/scripts/buildnr.pl @@ -0,0 +1,26 @@ +#!/usr/bin/perl + +# The yChat Project (2003) +# +# This script increases the BUILNR of msgs,h each time the yChat +# gets recompiled! + +use strict; + +open MSGS, "src/msgs.h"; +my @msgs = <MSGS>; +close MSGS; + +foreach (@msgs) +{ + if ( /define BUILDNR/ ) + { + s/(BUILDNR )(.+)$/$1.($2+1)/e; + print; + next; + } +} + +open MSGS, ">src/msgs.h"; +print MSGS @msgs; +close MSGS; |
