Skip to content
Permalink
Browse files

Remove @author tags and names from source code.

- Added checkstyle check for @author
- Added not to CONTRIBUTING.md saying that we don't use names in the codebase
  • Loading branch information...
ldaley committed Jul 22, 2013
1 parent 5173fbc commit a1b9612fa06f90f20b115cede557e22287501034
Showing 1,214 changed files with 321 additions and 3,626 deletions.
@@ -39,6 +39,7 @@ All code contributions should contain the following:
1. Unit Tests (we love Spock) for any logic introduced.
2. Integration Test coverage of the bug/feature at the level of build execution.
3. Documentation coverage in the UserGuide, DSL Reference and JavaDocs where appropriate.
4. Javadoc `@author` tags and committer names are not used in the codebase (contributions are recognised in the commit history and release notes)

If you're not sure where to start, ask on the developer list. There's likely a number of existing examples to help get you going.

@@ -17,14 +17,11 @@
package org.gradle.build

import org.gradle.api.tasks.bundling.Jar
import org.gradle.api.*
import org.gradle.api.file.*
import org.gradle.api.tasks.*
import com.tonicsystems.jarjar.Main as JarJarMain

/*
* a Jar task that performs JarJar repackaging after archive is created
* */
*/
class JarJarJar extends Jar {
@Input def rules = [:]
@Input def keeps = []
@@ -19,8 +19,6 @@ import org.w3c.dom.Element

/**
* Validates sample element - looks for missing attributes.
*
* @author Tomek Kaczanowski
*/
public class SampleElementValidator {

@@ -111,6 +111,9 @@
<module name="RegexpSingleline">
<property name="format" value="Created with IntelliJ IDEA"/>
</module>
<module name="RegexpSingleline">
<property name="format" value="^\s*\*\s*@author"/>
</module>

<!-- allows suppressing using the //CHECKSTYLE:ON //CHECKSTYLE:OFF -->
<module name="SuppressionCommentFilter"/>
@@ -21,8 +21,6 @@ import org.gradle.api.Project

/**
* This plugin allows to send announce messages to Twitter.
*
* @author hackergarten
*/
class AnnouncePlugin implements Plugin<Project> {
void apply(Project project) {
@@ -17,9 +17,6 @@ package org.gradle.api.plugins.announce.internal

import org.gradle.api.plugins.announce.Announcer

/**
* @author Hans Dockter
*/
interface AnnouncerFactory {
Announcer createAnnouncer(String type)
}
@@ -22,9 +22,6 @@ import org.gradle.api.plugins.announce.AnnouncePluginExtension
import org.gradle.api.plugins.announce.Announcer
import org.gradle.internal.os.OperatingSystem

/**
* @author Hans Dockter
*/
class DefaultAnnouncerFactory implements AnnouncerFactory {
private final AnnouncePluginExtension announcePluginConvention
private final IconProvider iconProvider
@@ -23,10 +23,7 @@ import org.gradle.internal.os.OperatingSystem

/**
* This class wraps the Ubuntu Notify Send functionality.
*
* @author Hackergarten
*/

class NotifySend implements Announcer {
private final IconProvider iconProvider
private final ProcessOperations processOperations
@@ -14,17 +14,15 @@
* limitations under the License.
*/

package org.gradle.api.plugins.announce.internal;
package org.gradle.api.plugins.announce.internal

import org.gradle.api.plugins.announce.Announcer
import org.slf4j.Logger
import org.slf4j.LoggerFactory
import sun.misc.BASE64Encoder
import org.slf4j.Logger
import org.gradle.api.plugins.announce.Announcer

/**
* This class allows to send announce messages to Twitter.
*
* @author Hackergarten
*/
class Twitter implements Announcer {
private static final Logger logger = LoggerFactory.getLogger(Twitter)
@@ -17,12 +17,8 @@ package org.gradle.api.plugins.announce

import org.gradle.api.internal.project.ProjectInternal
import org.gradle.api.plugins.announce.internal.AnnouncerFactory
import spock.lang.Specification
import org.gradle.util.HelperUtil

/**
* @author Hans Dockter
*/
import spock.lang.Specification

class AnnouncePluginExtensionTest extends Specification {
final AnnouncerFactory announcerFactory = Mock()
@@ -15,13 +15,10 @@
*/
package org.gradle.api.plugins.announce

import spock.lang.Specification
import org.gradle.util.HelperUtil
import org.gradle.api.Project
import org.gradle.util.HelperUtil
import spock.lang.Specification

/**
* @author Hans Dockter
*/
class AnnouncePluginTest extends Specification {
AnnouncePlugin announcePlugin = new AnnouncePlugin()
Project project = HelperUtil.createRootProject()
@@ -21,9 +21,6 @@ import org.gradle.internal.os.OperatingSystem
import org.gradle.util.HelperUtil
import spock.lang.Specification

/**
* @author Hans Dockter
*/
class DefaultAnnouncerFactoryTest extends Specification {
final project = HelperUtil.createRootProject()
final extension = new AnnouncePluginExtension(project)
@@ -36,8 +36,6 @@

/**
* A plugin for adding Antlr support to {@link JavaPlugin java projects}.
*
* @author Steve Ebersole
*/
public class AntlrPlugin implements Plugin<ProjectInternal> {
public static final String ANTLR_CONFIGURATION_NAME = "antlr";
@@ -24,8 +24,6 @@
* injecting a virtual directory named 'antlr' into the project's various {@link org.gradle.api.tasks.SourceSet source
* sets}. Its implementation gets pushed onto the {@link org.gradle.api.internal.DynamicObjectAware} portion of the
* source set under the name 'antlr'.
*
* @author Steve Ebersole
*/
public interface AntlrSourceVirtualDirectory {
public static final String NAME = "antlr";
@@ -16,24 +16,24 @@

package org.gradle.api.plugins.antlr;

import java.io.File;
import java.util.List;

import org.apache.tools.ant.taskdefs.optional.ANTLR;
import org.apache.tools.ant.types.Path;
import org.gradle.api.file.FileCollection;
import org.gradle.api.plugins.antlr.internal.GenerationPlan;
import org.gradle.api.plugins.antlr.internal.GenerationPlanBuilder;
import org.gradle.api.plugins.antlr.internal.MetadataExtracter;
import org.gradle.api.plugins.antlr.internal.XRef;
import org.gradle.api.tasks.InputFiles;
import org.gradle.api.tasks.OutputDirectory;
import org.gradle.api.tasks.SourceTask;
import org.gradle.api.tasks.TaskAction;
import org.gradle.api.plugins.antlr.internal.MetadataExtracter;
import org.gradle.api.plugins.antlr.internal.XRef;
import org.gradle.api.plugins.antlr.internal.GenerationPlanBuilder;
import org.gradle.util.GFileUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.io.File;
import java.util.List;

/**
* <p>Generates parsers from Antlr grammars.</p>
*
@@ -42,8 +42,6 @@
* classpath it uses to perform generation execution. This <b>should</b> really only require the antlr jar. In {@link
* AntlrPlugin} usage, this would happen simply by adding your antlr jar into the 'antlr' dependency configuration
* created and exposed by the {@link AntlrPlugin} itself.</p>
*
* @author Steve Ebersole
*/
public class AntlrTask extends SourceTask {
private static final Logger LOGGER = LoggerFactory.getLogger(AntlrTask.class);
@@ -24,8 +24,6 @@

/**
* The implementation of the {@link org.gradle.api.plugins.antlr.AntlrSourceVirtualDirectory} contract.
*
* @author Steve Ebersole
*/
public class AntlrSourceVirtualDirectoryImpl implements AntlrSourceVirtualDirectory {
private final SourceDirectorySet antlr;
@@ -19,8 +19,6 @@

/**
* Models information relevant to generation of a particular Antlr grammar file.
*
* @author Steve Ebersole
*/
public class GenerationPlan {
private final File source;
@@ -15,21 +15,19 @@
*/
package org.gradle.api.plugins.antlr.internal;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.io.File;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Iterator;
import java.util.ArrayList;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
* Builder for the properly order list of {@link GenerationPlan generation plans}.
*
* <p>IMPL NOTE : Uses recursive calls to achieve ordering.</p>
*
* @author Steve Ebersole
*/
public class GenerationPlanBuilder {
private static final Logger LOGGER = LoggerFactory.getLogger(GenerationPlanBuilder.class);
@@ -15,19 +15,17 @@
*/
package org.gradle.api.plugins.antlr.internal;

import antlr.collections.impl.IndexedVector;
import antlr.preprocessor.GrammarFile;

import java.lang.reflect.Method;
import java.util.Enumeration;
import java.util.ArrayList;
import java.util.Enumeration;
import java.util.List;

import antlr.collections.impl.IndexedVector;
import antlr.preprocessor.GrammarFile;

/**
* Antlr defines its {@link antlr.preprocessor.Grammar} class as package-protected for some unfortunate reason. So this class acts as a delegate to the Antlr {@link antlr.preprocessor.Grammar} class,
* hiding all the ugly necessary reflection code.
*
* @author Steve Ebersole
*/
public class GrammarDelegate {
public static List<GrammarDelegate> extractGrammarDelegates(GrammarFile antlrGrammarFile) {
@@ -15,15 +15,13 @@
*/
package org.gradle.api.plugins.antlr.internal;

import java.util.List;
import java.util.ArrayList;
import java.io.File;
import java.util.ArrayList;
import java.util.List;

/**
* Models information about an Antlr grammar file, including the inidividual {@link #getGrammars grammars} (lexers,
* parsers, etc) contained within it.
*
* @author Steve Ebersole
*/
public class GrammarFileMetadata {
private final File filePath;
@@ -15,15 +15,13 @@
*/
package org.gradle.api.plugins.antlr.internal;

import java.io.File;

import antlr.TreeParser;
import antlr.Parser;
import antlr.TreeParser;

import java.io.File;

/**
* Models a grammar defined within an Antlr grammar file.
*
* @author Steve Ebersole
*/
public class GrammarMetadata {
private final GrammarFileMetadata grammarFileMetadata;
@@ -15,20 +15,14 @@
*/
package org.gradle.api.plugins.antlr.internal;

import java.io.File;
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.io.FileNotFoundException;

import org.gradle.api.UncheckedIOException;
import org.gradle.api.file.FileTree;

import java.io.*;

/**
* Preprocess an Antlr grammar file so that dependencies between grammars can be properly determined such that they can
* be processed for generation in proper order later.
*
* @author Steve Ebersole
*/
public class MetadataExtracter {

@@ -15,17 +15,15 @@
*/
package org.gradle.api.plugins.antlr.internal;

import java.util.LinkedHashMap;
import antlr.preprocessor.Hierarchy;

import java.util.HashMap;
import java.util.Iterator;

import antlr.preprocessor.Hierarchy;
import java.util.LinkedHashMap;

/**
* Models cross-reference (x-ref) info about {@link GrammarFileMetadata grammar files} such as {@link #filesByPath},
* {@link #filesByExportVocab} and {@link #filesByClassName}.
*
* @author Steve Ebersole
*/
public class XRef {
private final Hierarchy antlrHierarchy;
@@ -26,7 +26,6 @@
* A {@link org.gradle.api.specs.CompositeSpec} which requires all its specs to be true in order to evaluate to true.
* Uses lazy evaluation.
*
* @author Hans Dockter
* @param <T> The target type for this Spec
*/
public class AndSpec<T> extends CompositeSpec<T> {
@@ -18,8 +18,6 @@

/**
* <p><code>GradleException</code> is the base class of all exceptions thrown by Gradle.</p>
*
* @author Hans Dockter
*/
public class GradleException extends RuntimeException {
public GradleException() {
@@ -23,7 +23,6 @@
/**
* A {@link org.gradle.api.specs.Spec} which aggregates a sequence of other {@code Spec} instances.
*
* @author Hans Dockter
* @param <T> The target type for this Spec
*/
abstract public class CompositeSpec<T> implements Spec<T> {
@@ -18,7 +18,6 @@
/**
* A {@link org.gradle.api.specs.Spec} implementation which negates another {@code Spec}.
*
* @author Hans Dockter
* @param <T> The target type for this Spec
*/
public class NotSpec<T> implements Spec<T> {
@@ -21,7 +21,6 @@
* A {@link CompositeSpec} which requires any one of its specs to be true in order to evaluate to
* true. Uses lazy evaluation.
*
* @author Hans Dockter
* @param <T> The target type for this Spec
*/
public class OrSpec<T> extends CompositeSpec<T> {

0 comments on commit a1b9612

Please sign in to comment.
You can’t perform that action at this time.