protected static Commandline createTagCommandLine()

in src/main/java/org/apache/maven/plugins/changelog/scm/provider/svn/svnexe/command/info/SvnInfoCommandExpanded.java [136:176]


    protected static Commandline createTagCommandLine(
            final SvnScmProviderRepository repository,
            final ScmFileSet fileSet,
            final String tag,
            final boolean recursive,
            final String revision) {
        Commandline cl = SvnCommandLineUtils.getBaseSvnCommandLine(fileSet.getBasedir(), repository);

        cl.createArg().setValue("info");

        if (recursive) {
            cl.createArg().setValue("--recursive");
        }

        if (revision != null && !revision.isEmpty()) {
            cl.createArg().setValue("-r");
            cl.createArg().setValue(revision);
        }

        Iterator<File> it = fileSet.getFileList().iterator();

        if (!it.hasNext()) {
            String tagUrl = SvnTagBranchUtils.resolveTagUrl(repository, new ScmTag(tag));
            cl.createArg().setValue(SvnCommandUtils.fixUrl(tagUrl, repository.getUser()));
        } else {
            while (it.hasNext()) {
                File file = it.next();

                if (repository == null) {
                    cl.createArg().setValue(file.getPath());
                } else {
                    // Note: this currently assumes you have the tag base checked out too
                    String tagUrl = SvnTagBranchUtils.resolveTagUrl(repository, new ScmTag(tag)) + "/"
                            + file.getPath().replace('\\', '/');
                    cl.createArg().setValue(SvnCommandUtils.fixUrl(tagUrl, repository.getUser()));
                }
            }
        }

        return cl;
    }