Package org.apache.maven.scm.provider.jazz.command

Examples of org.apache.maven.scm.provider.jazz.command.JazzScmCommand


        }

        // Now that we have a list of files to process, we can "add" (scm checkin) them.
        JazzAddConsumer addConsumer = new JazzAddConsumer( repo, getLogger() );
        ErrorConsumer errConsumer = new ErrorConsumer( getLogger() );
        JazzScmCommand command = createAddCommand( repo, fileSet );

        int status = command.execute( addConsumer, errConsumer );
        if ( status != 0 || errConsumer.hasBeenFed() )
        {
            return new AddScmResult( command.getCommandString(),
                                     "Error code for Jazz SCM add (checkin) command - " + status,
                                     errConsumer.getOutput(), false );
        }

        return new AddScmResult( command.getCommandString(), addConsumer.getFiles() );
    }
View Full Code Here


        return new AddScmResult( command.getCommandString(), addConsumer.getFiles() );
    }

    public JazzScmCommand createAddCommand( ScmProviderRepository repo, ScmFileSet fileSet )
    {
        JazzScmCommand command =
            new JazzScmCommand( JazzConstants.CMD_CHECKIN, null, repo, false, fileSet, getLogger() );

        List<File> files = fileSet.getFileList();
        if ( files != null && !files.isEmpty() )
        {
            for ( File file : files )
            {
                command.addArgument( file.getPath() ); // Check in only the files specified
            }
        }
        else
        {
            command.addArgument( "." ); // This will check in all local changes
        }

        return command;
    }
View Full Code Here

TOP

Related Classes of org.apache.maven.scm.provider.jazz.command.JazzScmCommand

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.