Removed svn Id tag
[MPC.git] / modules / Version.pm
blob3c5db288c6259df128d1f6b4c1af529ff33c2c02
1 package Version;
3 # ************************************************************
4 # Description : Central location for the MPC version.
5 # Author : Chad Elliott
6 # Create Date : 1/5/2003
7 # ************************************************************
9 # ************************************************************
10 # Pragmas
11 # ************************************************************
13 use strict;
15 # ************************************************************
16 # Data Section
17 # ************************************************************
19 ## This is the starting major and minor version
20 my $version = '4.1';
21 my $once = 1;
23 # ************************************************************
24 # Subroutine Section
25 # ************************************************************
27 sub get {
28 if ($once) {
29 ## We only need to do this once
30 $once = 0;
32 ## Here we determine the beta version. The base variable
33 ## is the negated number of existing ChangeLog entries at the
34 ## time of the release of the major and minor version. We then
35 ## add the total number of ChangeLog entries to the base to
36 ## get the beta version.
37 my $base = -1;
38 if (open(CLH, ::getBasePath() . '/ChangeLog')) {
39 while(<CLH>) {
40 if (/^\w\w\w\s\w\w\w\s/) {
41 ++$base;
44 close(CLH);
46 ## We then append the beta version number to the version string
47 $version .= ".$base";
49 else {
50 $version .= '.??';
54 return $version;