CPD Results

The following document contains the results of PMD's CPD 6.55.0.

Duplications

File Line
org\apache\maven\scm\provider\svn\svnexe\command\branch\SvnBranchCommand.java 81
org\apache\maven\scm\provider\svn\svnexe\command\tag\SvnTagCommand.java 101
Commandline cl = createCommandLine(repository, fileSet.getBasedir(), branch, messageFile, scmBranchParameters);

        CommandLineUtils.StringStreamConsumer stdout = new CommandLineUtils.StringStreamConsumer();

        CommandLineUtils.StringStreamConsumer stderr = new CommandLineUtils.StringStreamConsumer();

        if (logger.isInfoEnabled()) {
            logger.info("Executing: " + SvnCommandLineUtils.cryptPassword(cl));

            if (Os.isFamily(Os.FAMILY_WINDOWS)) {
                logger.info("Working directory: " + cl.getWorkingDirectory().getAbsolutePath());
            }
        }

        int exitCode;

        try {
            exitCode = SvnCommandLineUtils.execute(cl, stdout, stderr);
        } catch (CommandLineException ex) {
            throw new ScmException("Error while executing command.", ex);
        } finally {
            try {
                FileUtils.forceDelete(messageFile);
            } catch (IOException ex) {
                // ignore
            }
        }

        if (exitCode != 0) {
            return new BranchScmResult(cl.toString(), "The svn branch command failed.", stderr.getOutput(), false);
File Line
org\apache\maven\scm\provider\svn\svnexe\command\checkin\SvnCheckInCommand.java 67
org\apache\maven\scm\provider\svn\svnexe\command\mkdir\SvnMkdirCommand.java 62
SvnCheckInConsumer consumer = new SvnCheckInConsumer(fileSet.getBasedir());

        CommandLineUtils.StringStreamConsumer stderr = new CommandLineUtils.StringStreamConsumer();

        if (logger.isInfoEnabled()) {
            logger.info("Executing: " + SvnCommandLineUtils.cryptPassword(cl));

            if (Os.isFamily(Os.FAMILY_WINDOWS)) {
                logger.info("Working directory: " + cl.getWorkingDirectory().getAbsolutePath());
            }
        }

        int exitCode;

        try {
            exitCode = SvnCommandLineUtils.execute(cl, consumer, stderr);
        } catch (CommandLineException ex) {
            throw new ScmException("Error while executing command.", ex);
        } finally {
            try {
                FileUtils.forceDelete(messageFile);
            } catch (IOException ex) {
                // ignore
            }
        }

        if (exitCode != 0) {
            return new CheckInScmResult(cl.toString(), "The svn command failed.", stderr.getOutput(), false);
File Line
org\apache\maven\scm\provider\svn\svnexe\command\diff\SvnDiffCommand.java 52
org\apache\maven\scm\provider\svn\svnexe\command\status\SvnStatusCommand.java 43
org\apache\maven\scm\provider\svn\svnexe\command\update\SvnUpdateCommand.java 56
SvnDiffConsumer consumer = new SvnDiffConsumer(fileSet.getBasedir());

        CommandLineUtils.StringStreamConsumer stderr = new CommandLineUtils.StringStreamConsumer();

        if (logger.isInfoEnabled()) {
            logger.info("Executing: " + SvnCommandLineUtils.cryptPassword(cl));

            if (Os.isFamily(Os.FAMILY_WINDOWS)) {
                logger.info("Working directory: " + cl.getWorkingDirectory().getAbsolutePath());
            }
        }

        int exitCode;

        try {
            exitCode = SvnCommandLineUtils.execute(cl, consumer, stderr);
        } catch (CommandLineException ex) {
            throw new ScmException("Error while executing command.", ex);
        }

        if (exitCode != 0) {
            return new DiffScmResult(cl.toString(), "The svn command failed.", stderr.getOutput(), false);
File Line
org\apache\maven\scm\provider\svn\svnexe\command\add\SvnAddCommand.java 57
org\apache\maven\scm\provider\svn\svnexe\command\blame\SvnBlameCommand.java 49
org\apache\maven\scm\provider\svn\svnexe\command\info\SvnInfoCommand.java 60
org\apache\maven\scm\provider\svn\svnexe\command\list\SvnListCommand.java 55
org\apache\maven\scm\provider\svn\svnexe\command\remove\SvnRemoveCommand.java 53
SvnAddConsumer consumer = new SvnAddConsumer();

        CommandLineUtils.StringStreamConsumer stderr = new CommandLineUtils.StringStreamConsumer();

        if (logger.isInfoEnabled()) {
            logger.info("Executing: " + SvnCommandLineUtils.cryptPassword(cl));

            if (Os.isFamily(Os.FAMILY_WINDOWS)) {
                logger.info("Working directory: " + cl.getWorkingDirectory().getAbsolutePath());
            }
        }

        int exitCode;

        try {
            exitCode = SvnCommandLineUtils.execute(cl, consumer, stderr);
        } catch (CommandLineException ex) {
            throw new ScmException("Error while executing command.", ex);
        }

        if (exitCode != 0) {
            return new AddScmResult(cl.toString(), "The svn command failed.", stderr.getOutput(), false);
File Line
org\apache\maven\scm\provider\svn\svnexe\command\add\SvnAddCommand.java 57
org\apache\maven\scm\provider\svn\svnexe\command\blame\SvnBlameCommand.java 49
org\apache\maven\scm\provider\svn\svnexe\command\diff\SvnDiffCommand.java 52
org\apache\maven\scm\provider\svn\svnexe\command\info\SvnInfoCommand.java 60
org\apache\maven\scm\provider\svn\svnexe\command\list\SvnListCommand.java 55
org\apache\maven\scm\provider\svn\svnexe\command\remove\SvnRemoveCommand.java 53
org\apache\maven\scm\provider\svn\svnexe\command\status\SvnStatusCommand.java 43
org\apache\maven\scm\provider\svn\svnexe\command\update\SvnUpdateCommand.java 56
SvnAddConsumer consumer = new SvnAddConsumer();

        CommandLineUtils.StringStreamConsumer stderr = new CommandLineUtils.StringStreamConsumer();

        if (logger.isInfoEnabled()) {
            logger.info("Executing: " + SvnCommandLineUtils.cryptPassword(cl));

            if (Os.isFamily(Os.FAMILY_WINDOWS)) {
                logger.info("Working directory: " + cl.getWorkingDirectory().getAbsolutePath());
            }
        }

        int exitCode;

        try {
            exitCode = SvnCommandLineUtils.execute(cl, consumer, stderr);
        } catch (CommandLineException ex) {
            throw new ScmException("Error while executing command.", ex);
        }

        if (exitCode != 0) {
            return new AddScmResult(cl.toString(), "The svn command failed.", stderr.getOutput(), false);
File Line
org\apache\maven\scm\provider\svn\svnexe\command\branch\SvnBranchCommand.java 81
org\apache\maven\scm\provider\svn\svnexe\command\tag\SvnTagCommand.java 101
org\apache\maven\scm\provider\svn\svnexe\command\untag\SvnUntagCommand.java 74
Commandline cl = createCommandLine(repository, fileSet.getBasedir(), branch, messageFile, scmBranchParameters);

        CommandLineUtils.StringStreamConsumer stdout = new CommandLineUtils.StringStreamConsumer();

        CommandLineUtils.StringStreamConsumer stderr = new CommandLineUtils.StringStreamConsumer();

        if (logger.isInfoEnabled()) {
            logger.info("Executing: " + SvnCommandLineUtils.cryptPassword(cl));

            if (Os.isFamily(Os.FAMILY_WINDOWS)) {
                logger.info("Working directory: " + cl.getWorkingDirectory().getAbsolutePath());
            }
        }

        int exitCode;

        try {
            exitCode = SvnCommandLineUtils.execute(cl, stdout, stderr);
        } catch (CommandLineException ex) {
            throw new ScmException("Error while executing command.", ex);
File Line
org\apache\maven\scm\provider\svn\svnexe\command\checkin\SvnCheckInCommand.java 67
org\apache\maven\scm\provider\svn\svnexe\command\diff\SvnDiffCommand.java 52
org\apache\maven\scm\provider\svn\svnexe\command\status\SvnStatusCommand.java 43
org\apache\maven\scm\provider\svn\svnexe\command\update\SvnUpdateCommand.java 56
SvnCheckInConsumer consumer = new SvnCheckInConsumer(fileSet.getBasedir());

        CommandLineUtils.StringStreamConsumer stderr = new CommandLineUtils.StringStreamConsumer();

        if (logger.isInfoEnabled()) {
            logger.info("Executing: " + SvnCommandLineUtils.cryptPassword(cl));

            if (Os.isFamily(Os.FAMILY_WINDOWS)) {
                logger.info("Working directory: " + cl.getWorkingDirectory().getAbsolutePath());
            }
        }

        int exitCode;

        try {
            exitCode = SvnCommandLineUtils.execute(cl, consumer, stderr);
        } catch (CommandLineException ex) {
            throw new ScmException("Error while executing command.", ex);
        } finally {