Package org.apache.maven.scm

Examples of org.apache.maven.scm.ScmRevision


    }

    public void testCommandLineWithStartVersionAndEndVersionEquals()
        throws Exception
    {
        testCommandLine( "scm:git:http://foo.com/git", null, new ScmRevision( "1" ), new ScmRevision( "1" ),
                         "git whatchanged --date=iso 1..1"
                         + " -- " + StringUtils.quoteAndEscape( workingDirectory.getPath(), '"' ) );
    }
View Full Code Here


    }

    public void testCommandLineWithStartVersionAndEndVersionAndBranch()
        throws Exception
    {
        testCommandLine( "scm:git:http://foo.com/git", new ScmBranch( "my-test-branch" ), new ScmRevision( "1" ), new ScmRevision( "10" ),
                         "git whatchanged --date=iso 1..10 my-test-branch"
                         + " -- " + StringUtils.quoteAndEscape( workingDirectory.getPath(), '"' ) );
    }
View Full Code Here

            return new ScmTag( version );
        }

        if ( "revision".equals( versionType ) )
        {
            return new ScmRevision( version );
        }

        throw new MojoExecutionException( "Unknown '" + versionType + "' version type." );
    }
View Full Code Here

        }
        if ( scmVersion.length() > 0 )
        {
            if ( "revision".equals( scmVersionType ) )
            {
                return new ScmRevision( scmVersion );
            }
            else if ( "tag".equals( scmVersionType ) )
            {
                return new ScmTag( scmVersion );
            }
View Full Code Here

            if ( endDate == null )
            {
                endDate = toTransaction.getWhen();
            }
        }
        startVersion = new ScmRevision( repository.getRevision( stream, fromTranId ) );
        endVersion = new ScmRevision( repository.getRevision( stream, toTranId ) );

        //TODO Split this method in two here. above to convert params to start and end (stream,tranid,date) and test independantly
       
        List<Transaction> streamHistory = Collections.emptyList();
        List<Transaction> workspaceHistory = Collections.emptyList();
View Full Code Here

        if ( result.isSuccess() && parameters.getBoolean( CommandParameter.RUN_CHANGELOG_WITH_UPDATE ) )
        {
            AccuRevUpdateScmResult accuRevResult = (AccuRevUpdateScmResult) result;

            ScmRevision fromRevision = new ScmRevision( accuRevResult.getFromRevision() );
            ScmRevision toRevision = new ScmRevision( accuRevResult.getToRevision() );

            parameters.setScmVersion( CommandParameter.START_SCM_VERSION, fromRevision );
            parameters.setScmVersion( CommandParameter.END_SCM_VERSION, toRevision );

            AccuRevVersion startVersion = accurevRepo.getAccuRevVersion( fromRevision );
View Full Code Here

            return new ScmTag( version );
        }

        if ( "revision".equals( versionType ) )
        {
            return new ScmRevision( version );
        }

        throw new MojoExecutionException( "Unknown '" + versionType + "' version type." );
    }
View Full Code Here

            if ( endDate == null )
            {
                endDate = toTransaction.getWhen();
            }
        }
        startVersion = new ScmRevision( repository.getRevision( stream, fromTranId ) );
        endVersion = new ScmRevision( repository.getRevision( stream, toTranId ) );

        //TODO Split this method in two here. above to convert params to start and end (stream,tranid,date) and test independantly
       
        List<Transaction> streamHistory = Collections.emptyList();
        List<Transaction> workspaceHistory = Collections.emptyList();
View Full Code Here

                {
                    scmVersion = new ScmBranch( version );
                }
                else if ( "revision".equals( type ) )
                {
                    scmVersion = new ScmRevision( version );
                }
                else
                {
                    throw new IllegalArgumentException( "'" + type + "' version type isn't known." );
                }
            }
            else
            {
                scmVersion = new ScmRevision( args[3] );
            }
        }

        cli.execute( scmUrl, command, workingDirectory, scmVersion );
View Full Code Here

        throws Exception
    {
        Date startDate = getDate( 2003, Calendar.SEPTEMBER, 10, 1, 1, 1, GMT_TIME_ZONE );
        Date endDate = getDate( 2005, Calendar.NOVEMBER, 13, 23, 23, 23, GMT_TIME_ZONE );
   
        testCommandLine( "scm:git:http://foo.com/git", null, startDate, endDate, new ScmRevision( "1" ), new ScmRevision( "10" ),
                         "git whatchanged \"--since=2003-09-10 01:01:01 +0000\" \"--until=2005-11-13 23:23:23 +0000\" --date=iso 1..10"
                         + " -- " + workingDirectory );
    }
View Full Code Here

TOP

Related Classes of org.apache.maven.scm.ScmRevision

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.