Subversion Repositories DevTools

Rev

Rev 5709 | Rev 6276 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5709 Rev 6177
Line 1... Line 1...
1
########################################################################
1
########################################################################
2
# Copyright (c) VIX TECHNOLOGY (AUST) LTD
2
# COPYRIGHT - VIX IP PTY LTD ("VIX"). ALL RIGHTS RESERVED.
3
#
3
#
4
# Module name   : jats_svnrelease.pl
4
# Module name   : jats_svnrelease.pl
5
# Module type   : Jats Utility
5
# Module type   : Jats Utility
6
# Compiler(s)   : Perl
6
# Compiler(s)   : Perl
7
# Environment(s): Jats
7
# Environment(s): Jats
Line 686... Line 686...
686
                               $workSpace,
686
                               $workSpace,
687
                               '--NoPrint' );
687
                               '--NoPrint' );
688
    }
688
    }
689
 
689
 
690
    #
690
    #
691
    #   Create a local package archive
-
 
692
    #   May be needed for multipackage builds and it will prevent JATS from
-
 
693
    #   finding any outside the view
-
 
694
    #
-
 
695
    mkdir ( $VIEWDIR . '/local_dpkg_archive')
-
 
696
        unless ($GBE_SANDBOX);
-
 
697
 
-
 
698
    #
-
 
699
    #   Display messages AFTER the extraction text
691
    #   Display messages AFTER the extraction text
700
    #   Will ensure that the user has a chance to see them
692
    #   Will ensure that the user has a chance to see them
701
    #
693
    #
702
    Warning(@messageText );
694
    Warning(@messageText );
703
    
695
    
Line 1145... Line 1137...
1145
 
1137
 
1146
    $svnSession->SvnCo ( $svnSession->FullPath() . '/' . $view_tag,
1138
    $svnSession->SvnCo ( $svnSession->FullPath() . '/' . $view_tag,
1147
                        $VIEWDIR,
1139
                        $VIEWDIR,
1148
                        'export' => 1,
1140
                        'export' => 1,
1149
                        'escrow' => $opt_escrow,
1141
                        'escrow' => $opt_escrow,
1150
                        'print' => 0 );
1142
                        'print'  => ($GBE_ABT ? 1 : 0) );
1151
 
1143
 
1152
    #
1144
    #
1153
    #   Count this files in the view
1145
    #   Count this files in the view
1154
    #   Done so that its clear when we have a empty workspace in escrow extractions
1146
    #   Done so that its clear when we have a empty workspace in escrow extractions
1155
    #
1147
    #
Line 1205... Line 1197...
1205
    #       Should only be one - but if the users have been bad
1197
    #       Should only be one - but if the users have been bad
1206
    #       then there may be more.
1198
    #       then there may be more.
1207
    #
1199
    #
1208
    if ( $data->{files} )
1200
    if ( $data->{files} )
1209
    {
1201
    {
1210
        foreach my $srcFile ( reverse @{$data->{files}} )
1202
        foreach my $item ( reverse @{$data->{files}} )
1211
        {
1203
        {
-
 
1204
            my ($srcFile, $action) = split( $;, $item);
1212
            Verbose("importTagChanges: $srcFile");
1205
            Verbose("importTagChanges ($action): $srcFile");
1213
            my $sfile = $svnSession->FullPath() . '/' . $srcFile;
1206
            my $sfile = $svnSession->FullPath() . '/' . $srcFile;
1214
 
1207
 
1215
            #
1208
            #
1216
            #   Calculate path within the repo of the target file
1209
            #   Calculate path within the repo of the target file
1217
            #
1210
            #
Line 1223... Line 1216...
1223
                #       aaa/bbbb/tags/badTag was a copy of aaa
1216
                #       aaa/bbbb/tags/badTag was a copy of aaa
1224
                #
1217
                #
1225
                Error ("importTagChanges. Unexpected format of filename: $srcFile",
1218
                Error ("importTagChanges. Unexpected format of filename: $srcFile",
1226
                       "Possible cause: Incorrect tag placement");
1219
                       "Possible cause: Incorrect tag placement");
1227
            }
1220
            }
-
 
1221
            my $rfile = $1;
1228
            my $tfile = $workSpace . $1;
1222
            my $tfile = $workSpace . $1;
1229
 
1223
            
1230
            if ( $opt_mkbranch )
1224
            if ($action eq 'D')
1231
            {
1225
            {
-
 
1226
                # File was deleted
-
 
1227
                my $mode = '-';
-
 
1228
                if (-f $tfile) {
1232
                $svnSession->SvnSwitch ($sfile, $tfile);
1229
                    unlink ( $tfile );
-
 
1230
                    $mode = ' ';
-
 
1231
                }
-
 
1232
                Information("Deleting  : D$mode   $VIEWPATH$rfile");
1233
            }
1233
            }
1234
            else
1234
            else
1235
            {
1235
            {
-
 
1236
                if ( $opt_mkbranch )
-
 
1237
                {
-
 
1238
                    $svnSession->SvnSwitch ($sfile, $tfile);
-
 
1239
                }
-
 
1240
                else
-
 
1241
                {
1236
                $svnSession->SvnCo ($sfile, $tfile,
1242
                    $svnSession->SvnCo ($sfile, $tfile,
1237
                                        'export' => 1,
1243
                                            'export' => 1,
1238
                                        'force' => 1,
1244
                                            'force' => 1,
1239
                                        'escrow' => $opt_escrow,
1245
                                            'escrow' => $opt_escrow,
1240
                                        'pretext' => 'Replacing ' );
1246
                                            'pretext' => 'Replacing ' );
-
 
1247
                }
1241
            }
1248
            }
1242
        }
1249
        }
1243
    }
1250
    }
1244
}
1251
}
1245
 
1252