Package org.apache.maven.scm.provider.integrity

Examples of org.apache.maven.scm.provider.integrity.Project


            // First validate the checkpoint label string by evaluating the groovy script
            String chkptLabel = evalGroovyExpression( tagName );
            Project.validateTag( chkptLabel );
            String msg = ( ( null == message || message.length() == 0 ) ? System.getProperty( "message" ) : message );
            // Get information about the Project
            Project siProject = iRepo.getProject();
            // Ensure this is not a build project configuration
            if ( !siProject.isBuild() )
            {
                Response res = siProject.checkpoint( msg, chkptLabel );
                int exitCode = res.getExitCode();
                boolean success = ( exitCode == 0 ? true : false );
                WorkItem wi = res.getWorkItem( siProject.getConfigurationPath() );
                String chkpt = wi.getResult().getField( "resultant" ).getItem().getId();
                getLogger().info(
                    "Successfully checkpointed project " + siProject.getConfigurationPath() + " with label '"
                        + chkptLabel + "', new revision is " + chkpt );
                result =
                    new TagScmResult( res.getCommandString(), wi.getResult().getMessage(), "Exit Code: " + exitCode,
                                      success );
            }
            else
            {
                getLogger().error(
                    "Cannot checkpoint a build project configuration: " + siProject.getConfigurationPath() + "!" );
                result =
                    new TagScmResult( "si checkpoint", "Cannot checkpoint a build project configuration!", "", false );
            }
        }
        catch ( CompilationFailedException cfe )
View Full Code Here


            int exitCode = res.getExitCode();
            boolean success = ( exitCode == 0 ? true : false );
            result = new LoginScmResult( res.getCommandString(), "", "Exit Code: " + exitCode, success );

            // Next we will prepare the Project and Sandbox for the other commands
            Project siProject = new Project( api, iRepo.getConfigruationPath() );
            Sandbox siSandbox = new Sandbox( api, siProject, fileSet.getBasedir().getAbsolutePath() );
            iRepo.setProject( siProject );
            iRepo.setSandbox( siSandbox );
        }
        catch ( APIException aex )
View Full Code Here

                                                 String branchName, String message )
        throws ScmException
    {
        BranchScmResult result;
        IntegrityScmProviderRepository iRepo = (IntegrityScmProviderRepository) repository;
        Project siProject = iRepo.getProject();
        getLogger().info(
            "Attempting to branch project " + siProject.getProjectName() + " using branch name '" + branchName + "'" );
        try
        {
            Project.validateTag( branchName );
            Response res = siProject.createDevPath( branchName );
            int exitCode = res.getExitCode();
            boolean success = ( exitCode == 0 ? true : false );
            ScmResult scmResult = new ScmResult( res.getCommandString(), "", "Exit Code: " + exitCode, success );
            result = new BranchScmResult( new ArrayList<ScmFile>(), scmResult );
        }
View Full Code Here

            int exitCode = res.getExitCode();
            boolean success = ( exitCode == 0 ? true : false );
            result = new LoginScmResult( res.getCommandString(), "", "Exit Code: " + exitCode, success );

            // Next we will prepare the Project and Sandbox for the other commands
            Project siProject = new Project( api, iRepo.getConfigruationPath() );
            Sandbox siSandbox = new Sandbox( api, siProject, fileSet.getBasedir().getAbsolutePath() );
            iRepo.setProject( siProject );
            iRepo.setSandbox( siSandbox );
        }
        catch ( APIException aex )
View Full Code Here

                                                 String branchName, String message )
        throws ScmException
    {
        BranchScmResult result;
        IntegrityScmProviderRepository iRepo = (IntegrityScmProviderRepository) repository;
        Project siProject = iRepo.getProject();
        getLogger().info(
            "Attempting to branch project " + siProject.getProjectName() + " using branch name '" + branchName + "'" );
        try
        {
            Project.validateTag( branchName );
            Response res = siProject.createDevPath( branchName );
            int exitCode = res.getExitCode();
            boolean success = ( exitCode == 0 ? true : false );
            ScmResult scmResult = new ScmResult( res.getCommandString(), "", "Exit Code: " + exitCode, success );
            result = new BranchScmResult( new ArrayList<ScmFile>(), scmResult );
        }
View Full Code Here

            // First validate the checkpoint label string by evaluating the groovy script
            String chkptLabel = evalGroovyExpression( tagName );
            Project.validateTag( chkptLabel );
            String msg = ( ( null == message || message.length() == 0 ) ? System.getProperty( "message" ) : message );
            // Get information about the Project
            Project siProject = iRepo.getProject();
            // Ensure this is not a build project configuration
            if ( !siProject.isBuild() )
            {
                Response res = siProject.checkpoint( msg, chkptLabel );
                int exitCode = res.getExitCode();
                boolean success = ( exitCode == 0 ? true : false );
                WorkItem wi = res.getWorkItem( siProject.getConfigurationPath() );
                String chkpt = wi.getResult().getField( "resultant" ).getItem().getId();
                getLogger().info(
                    "Successfully checkpointed project " + siProject.getConfigurationPath() + " with label '"
                        + chkptLabel + "', new revision is " + chkpt );
                result =
                    new TagScmResult( res.getCommandString(), wi.getResult().getMessage(), "Exit Code: " + exitCode,
                                      success );
            }
            else
            {
                getLogger().error(
                    "Cannot checkpoint a build project configuration: " + siProject.getConfigurationPath() + "!" );
                result =
                    new TagScmResult( "si checkpoint", "Cannot checkpoint a build project configuration!", "", false );
            }
        }
        catch ( CompilationFailedException cfe )
View Full Code Here

TOP

Related Classes of org.apache.maven.scm.provider.integrity.Project

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.