Changeset 4177 for trunk


Ignore:
Timestamp:
2003-04-17T14:03:08+12:00 (21 years ago)
Author:
mdewsnip
Message:

Added check for third argument (use CVS or not).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/bin/script/inittranslation.pl

    r4163 r4177  
    4747    # Get the name of the target language
    4848    my $targetlang = shift(@_);
     49    my $usecvs = shift(@_);
    4950
    5051    # Check that both arguments were supplied
     
    144145    }
    145146
    146     # Use CVS to initialise the update database
    147     &initialise_update_db($sourcelang, $targetlang, $targethash, $macrosdir);
     147    # Use CVS to initialise the update database, if desired
     148    if ($usecvs && $usecvs eq "true") {
     149    &initialise_update_db($sourcelang, $targetlang, $targethash, $macrosdir);
     150    }
    148151
    149152    # Clean up
     
    417420    my $sourcedate = $annotatedsourcehash1->{$targetkey};
    418421    if (&is_date_before($targetdate, $sourcedate) eq "true") {
    419         print "Macro needs updating!!\n";
     422        # print "Macro needs updating!!\n";
    420423        $targetkey = &get_macrofile_name($targetlang, "") . "::" . $targetkey;
    421         print "Target key: $targetkey";
    422         print " Original target text: $targethash->{$targetkey}\n";
     424        # print "Target key: $targetkey";
     425        # print " Original target text: $targethash->{$targetkey}\n";
    423426        $updatedata{$targetkey} = $targethash->{$targetkey};
    424427    }
     
    429432    my $sourcedate = $annotatedsourcehash2->{$targetkey};
    430433    if (&is_date_before($targetdate, $sourcedate) eq "true") {
    431         print "Macro needs updating!!\n";
     434        # print "Macro needs updating!!\n";
    432435        $targetkey = &get_macrofile_name($targetlang, "2") . "::" . $targetkey;
    433         print "Target key: $targetkey";
    434         print " Original target text: $targethash->{$targetkey}\n";
     436        # print "Target key: $targetkey";
     437        # print " Original target text: $targethash->{$targetkey}\n";
    435438        $updatedata{$targetkey} = $targethash->{$targetkey};
    436439    }
Note: See TracChangeset for help on using the changeset viewer.