Commits

Sebastian Sdorra committed a5e1e9b

remove unused imports

  • Participants
  • Parent commits 2030e01

Comments (0)

Files changed (2)

File scm-plugins/scm-git-plugin/src/main/java/sonia/scm/repository/spi/GitLogCommand.java

 import com.google.common.base.Strings;
 import com.google.common.collect.Lists;
 
-import org.eclipse.jgit.api.Git;
-import org.eclipse.jgit.api.errors.GitAPIException;
-import org.eclipse.jgit.api.errors.NoHeadException;
-import org.eclipse.jgit.errors.IncorrectObjectTypeException;
-import org.eclipse.jgit.errors.MissingObjectException;
-import org.eclipse.jgit.errors.StopWalkException;
 import org.eclipse.jgit.lib.ObjectId;
 import org.eclipse.jgit.lib.Repository;
 import org.eclipse.jgit.revwalk.RevCommit;
 import org.eclipse.jgit.revwalk.RevWalk;
-import org.eclipse.jgit.revwalk.filter.RevFilter;
 import org.eclipse.jgit.treewalk.filter.AndTreeFilter;
 import org.eclipse.jgit.treewalk.filter.PathFilter;
-import org.eclipse.jgit.treewalk.filter.PathFilterGroup;
 import org.eclipse.jgit.treewalk.filter.TreeFilter;
 
 import org.slf4j.Logger;
 
 import java.io.IOException;
 
-import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
 
    */
   @Override
   public ChangesetPagingResult getChangesets(LogCommandRequest request)
-          throws IOException, RepositoryException
+    throws IOException, RepositoryException
   {
     if (logger.isDebugEnabled())
     {
         if (!Strings.isNullOrEmpty(request.getPath()))
         {
           revWalk.setTreeFilter(
-              AndTreeFilter.create(
-                PathFilter.create(request.getPath()), TreeFilter.ANY_DIFF));
+            AndTreeFilter.create(
+              PathFilter.create(request.getPath()), TreeFilter.ANY_DIFF));
         }
 
         ObjectId head = GitUtil.getRepositoryHead(gr);
             RevCommit commit = iterator.next();
 
             if ((counter >= start)
-                && ((limit < 0) || (counter < start + limit)))
+              && ((limit < 0) || (counter < start + limit)))
             {
               changesetList.add(converter.createChangeset(commit));
             }
       else if (logger.isWarnEnabled())
       {
         logger.warn("the repository {} seems to be empty",
-                    repository.getName());
+          repository.getName());
       }
     }
     catch (Exception ex)

File scm-plugins/scm-git-plugin/src/main/java/sonia/scm/repository/spi/GitTagsCommand.java

 
 import org.eclipse.jgit.api.Git;
 import org.eclipse.jgit.api.errors.GitAPIException;
-import org.eclipse.jgit.revwalk.RevTag;
+import org.eclipse.jgit.lib.Ref;
 
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import java.io.IOException;
 
 import java.util.List;
-import org.eclipse.jgit.lib.Ref;
 
 /**
  *
 public class GitTagsCommand extends AbstractGitCommand implements TagsCommand
 {
 
+  /** Field description */
+  private static final String PREFIX_TAG = "refs/tags/";
+
   /**
    * the logger for GitTagsCommand
    */
 
   //~--- get methods ----------------------------------------------------------
 
-  private static final String PREFIX_TAG = "refs/tags/";
-  
   /**
    * Method description
    *
         public Tag apply(Ref input)
         {
           String name = input.getName();
-          if ( name.startsWith(PREFIX_TAG) ){
+
+          if (name.startsWith(PREFIX_TAG))
+          {
             name = name.substring(PREFIX_TAG.length());
           }
+
           return new Tag(name, input.getObjectId().name());
         }