File: makerelease2.pl

package info (click to toggle)
therion 5.3.15-2
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 18,752 kB
  • ctags: 16,359
  • sloc: ansic: 128,859; cpp: 99,458; tcl: 25,577; perl: 2,094; makefile: 1,063; asm: 219; python: 54; sh: 4
file content (20 lines) | stat: -rw-r--r-- 375 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
if (open(VFL,"thversion.h")) {
  @verfl = <VFL>;
  $verfl[0] =~ /(\d+)\.(\d+)(\.(\d+))?/;
  ($v1,$v2,$v3) = ($1,$2,$4);
  if (!$v3) {
    $v3 = 0;
  }
  close(VFL);
  $v3++;
} else {
  $v1 = 0;
  $v2 = 0;
  $v3 = 0;
}
open(VFL,">thversion.h");
print VFL "#define THVERSION \"$v1.$v2.$v3\"\n";
close(VFL);
open(VFL,">thbook/version.tex");
print VFL "$v1.$v2.$v3";
close(VFL);