huangp@vm:~$

All geeky stuff

Set up Sonatype Nexus for maven repo

Sonatype nexus is a maven repository management tool. It has open source version and pro version. I am using the free open sourced one.
It has a quite comprehensive reference online for how to install and run it. Here is some simple notes.

  1. Download and extract content to some location. i.e. ~/tools/nexus
  2. Based on your machine running it, go to specific sub folder under nexus/webapp/bin/jsw. Mine is linux-x86-32
  3. Execute ./nexus start
  4. Open your browser and go to http://localhost:8081/nexus
  5. If you see it running, good.(initial login credential is admin/admin123)
  6. Open your maven settings.xml (If have more than one maven version, it’s best to put settings.xml under your ~/.m2 folder and rename all the ones under each maven conf folder. This way you only need to manage one settings)

Here is how to update the settins.xml file:
Under servers, add

<server>
    <id>nexus-releases</id>
    <username>admin</username>
    <password>admin123</password>
</server>
<server>
    <id>nexus-snapshot</id>
    <username>admin</username>
    <password>admin123</password>
</server>

Under mirrors, add

<mirror>
    <id>localnexus</id>
    <mirrorOf>*</mirrorOf>
    <name>local nexux</name>
    <url>http://localhost:8081/nexus/content/groups/public</url>
</mirror>

Under profiles, add

<profile>
    <id>nexus</id>
    <repositories>
        <repository>
            <id>local-nexus</id>
            <url>http://local</url>
            <releases>
                <enabled>true</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>local-nexus</id>
            <url>http://local</url>
            <releases>
                <enabled>true</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
        </pluginRepository>
    </pluginRepositories>
</profile>

Last make this profile always active

<activeProfiles>
    <activeProfile>nexus</activeProfile>
</activeProfiles>

Now try to run your maven and see if it works. Hopefully it will 🙂

Nexus by default will proxy a few popular public repositories like central and google code. In order to search artifacts, you will need to tell nexus to download index from those repository(by default it won’t). You can log in to nexus and for each repository, under configuration, change Download Remote Indexes to true. After save, you can right click the repository and select update index.

You can add more repositories to your nexus. Easiest way is to copy and paste:)
Thanks to my colleague Geoff FORD I have a copy from work. If you use default nexus settings, under nexus/sonatype-work/nexus/conf, there should be a nexus.xml file. Make a backup copy. Open and replace repositories section with following:

<repositories>
    <repository>
        <id>central</id>
        <name>central</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repo1.maven.org/maven2/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>inhouse</id>
        <name>inhouse</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>ALLOW_WRITE_ONCE</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>false</downloadRemoteIndex>
            <checksumPolicy>IGNORE</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
        </externalConfiguration>
    </repository>
    <repository>
        <id>inhouse.snapshot</id>
        <name>inhouse.snapshot</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>ALLOW_WRITE</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>false</downloadRemoteIndex>
            <checksumPolicy>IGNORE</checksumPolicy>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
        </externalConfiguration>
    </repository>
    <repository>
        <id>thirdparty</id>
        <name>3rd party</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>ALLOW_WRITE_ONCE</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>-1</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>false</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
        </externalConfiguration>
    </repository>
    <repository>
        <id>spring.milestone</id>
        <name>spring.milestone</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repository.springsource.com/maven/bundles/milestone/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>java.net.legacy</id>
        <name>java.net.legacy</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://download.java.net/maven/1/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>springframework</id>
        <name>springframework</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://static.springframework.org/maven2/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>java.net</id>
        <name>java.net</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://download.java.net/maven/2/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>openqa</id>
        <name>openqa</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://nexus.openqa.org/content/repositories/releases/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>apache.incubating</id>
        <name>apache.incubating</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://people.apache.org/repo/m2-incubating-repository/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>appfuse</id>
        <name>appfuse</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://static.appfuse.org/repository/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
        </externalConfiguration>
    </repository>
    <repository>
        <id>codehaus</id>
        <name>codehaus</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repository.codehaus.org/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>apache.snapshot</id>
        <name>apache.snapshot</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repository.apache.org/snapshots/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <fileTypeValidation>true</fileTypeValidation>
            <metadataMaxAge>1440</metadataMaxAge>
        </externalConfiguration>
    </repository>
    <repository>
        <id>codehaus.snapshot</id>
        <name>codehaus.snapshot</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://snapshots.repository.codehaus.org/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <fileTypeValidation>true</fileTypeValidation>
            <metadataMaxAge>1440</metadataMaxAge>
        </externalConfiguration>
    </repository>
    <repository>
        <id>atlassian.contrib</id>
        <name>atlassian.contrib</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://maven.atlassian.com/contrib/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>false</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>jfrog.plugins</id>
        <name>jfrog.plugins</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repo.jfrog.org/artifactory/plugins-releases/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>spring.external</id>
        <name>spring.external</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repository.springsource.com/maven/bundles/external/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>spring.release</id>
        <name>spring.release</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repository.springsource.com/maven/bundles/release/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>scala.releases</id>
        <name>scala.releases</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://scala-tools.org/repo-releases/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>scala.snapshots</id>
        <name>scala.snapshots</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://scala-tools.org/repo-snapshots/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>gwt-maven</id>
        <name>gwt-maven</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://gwt-maven.googlecode.com/svn/trunk/mavenrepo/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>google.releases</id>
        <name>google.releases</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://google-maven-repository.googlecode.com/svn/repository/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>google.snapshots</id>
        <name>google.snapshots</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://google-maven-repository.googlecode.com/svn/snapshot-repository/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>eviware</id>
        <name>eviware</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://www.eviware.com/repository/maven2/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>eviware.snapshot</id>
        <name>eviware.snapshot</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://www.eviware.com/repository/maven2/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>1440</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <fileTypeValidation>true</fileTypeValidation>
            <metadataMaxAge>1440</metadataMaxAge>
        </externalConfiguration>
    </repository>
    <repository>
        <id>powermock</id>
        <name>powermock</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://powermock.googlecode.com/svn/repo/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>mcrepo</id>
        <name>mcrepo</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://mc-repo.googlecode.com/svn/maven2/releases/</url>
        </remoteStorage>
        <externalConfiguration>
            <proxyMode>ALLOW</proxyMode>
            <artifactMaxAge>10080</artifactMaxAge>
            <itemMaxAge>1440</itemMaxAge>
            <cleanseRepositoryMetadata>false</cleanseRepositoryMetadata>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <checksumPolicy>WARN</checksumPolicy>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <autoBlockActive>true</autoBlockActive>
            <metadataMaxAge>1440</metadataMaxAge>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>public</id>
        <name>public</name>
        <providerRole>org.sonatype.nexus.proxy.repository.GroupRepository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>15</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <externalConfiguration>
            <mergeMetadata>true</mergeMetadata>
            <memberRepositories>
                <memberRepository>central</memberRepository>
                <memberRepository>apache.incubating</memberRepository>
                <memberRepository>apache.snapshot</memberRepository>
                <memberRepository>appfuse</memberRepository>
                <memberRepository>atlassian</memberRepository>
                <memberRepository>atlassian.contrib</memberRepository>
                <memberRepository>codehaus</memberRepository>
                <memberRepository>codehaus.snapshot</memberRepository>
                <memberRepository>eclipse</memberRepository>
                <memberRepository>eviware</memberRepository>
                <memberRepository>eviware.snapshot</memberRepository>
                <memberRepository>fusesource</memberRepository>
                <memberRepository>fusesource.public</memberRepository>
                <memberRepository>fusesource.snapshot</memberRepository>
                <memberRepository>google.releases</memberRepository>
                <memberRepository>google.snapshots</memberRepository>
                <memberRepository>gradle</memberRepository>
                <memberRepository>gwt-maven</memberRepository>
                <memberRepository>gwt-maven-2.1.0</memberRepository>
                <memberRepository>gwt-platform</memberRepository>
                <memberRepository>inhouse</memberRepository>
                <memberRepository>inhouse.snapshot</memberRepository>
                <memberRepository>ipsedixit-snapshot</memberRepository>
                <memberRepository>java.net</memberRepository>
                <memberRepository>java.net.legacy</memberRepository>
                <memberRepository>jboss-public</memberRepository>
                <memberRepository>JBoss.third.party</memberRepository>
                <memberRepository>jfrog.plugins</memberRepository>
                <memberRepository>mcrepo</memberRepository>
                <memberRepository>mcrepo.snapshots</memberRepository>
                <memberRepository>openqa</memberRepository>
                <memberRepository>powermock</memberRepository>
                <memberRepository>restlet</memberRepository>
                <memberRepository>scala.releases</memberRepository>
                <memberRepository>scala.snapshots</memberRepository>
                <memberRepository>smartgwt</memberRepository>
                <memberRepository>spring.external</memberRepository>
                <memberRepository>spring.milestone</memberRepository>
                <memberRepository>spring.release</memberRepository>
                <memberRepository>springframework</memberRepository>
                <memberRepository>SpringRoo</memberRepository>
                <memberRepository>thirdparty</memberRepository>
                <memberRepository>wso2</memberRepository>
                <memberRepository>sonatype-snapshots</memberRepository>
                <memberRepository>s3-spring-milestones</memberRepository>
            </memberRepositories>
        </externalConfiguration>
    </repository>
    <repository>
        <id>JBoss.third.party</id>
        <name>JBoss third party</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>https://repository.jboss.org/nexus/content/repositories/thirdparty-releases/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>false</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>-1</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>fusesource</id>
        <name>fusesource</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repo.fusesource.com/maven2/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>false</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>smartgwt</id>
        <name>smartgwt</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://www.smartclient.com/maven2/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>restlet</id>
        <name>restlet</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://maven.restlet.org/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>false</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>fusesource.snapshot</id>
        <name>fusesource.snapshot</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repo.fusesource.com/nexus/content/repositories/public-snapshots/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>1440</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>ipsedixit-snapshot</id>
        <name>ipsedixit-snapshot</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://ipsedixit.sourceforge.net/m2repo/snapshot/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>1440</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>atlassian</id>
        <name>atlassian</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://maven.atlassian.com/repository/public/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>fusesource.public</id>
        <name>fusesource.public</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repo.fusesource.com/nexus/content/repositories/public/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>jboss-public</id>
        <name>jboss-public</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://repository.jboss.org/nexus/content/groups/public-jboss/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
            <fileTypeValidation>true</fileTypeValidation>
        </externalConfiguration>
    </repository>
    <repository>
        <id>gwt-maven-2.1.0</id>
        <name>gwt-maven-2.1.0</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://google-web-toolkit.googlecode.com/svn/2.1.0/gwt/maven/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>true</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>mcrepo.snapshots</id>
        <name>mcrepo.snapshots</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://mc-repo.googlecode.com/svn/maven2/snapshots/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>true</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>1440</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>wso2</id>
        <name>wso2</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://dist.wso2.org/maven2/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>true</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>SpringRoo</id>
        <name>SpringRoo</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://spring-roo-repository.springsource.org/release/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>true</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>gwt-platform</id>
        <name>gwt-platform</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://maven.gwt-platform.googlecode.com/hg/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>false</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>-1</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>gradle</id>
        <name>gradle</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://gradle.artifactoryonline.com/gradle/distributions/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>false</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>eclipse</id>
        <name>eclipse</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://maven.eclipse.org/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>false</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>10080</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>sonatype-snapshots</id>
        <name>sonatype-snapshots</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>SNAPSHOT</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>true</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>1440</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
    <repository>
        <id>s3-spring-milestones</id>
        <name>s3-spring-milestones</name>
        <providerRole>org.sonatype.nexus.proxy.repository.Repository</providerRole>
        <providerHint>maven2</providerHint>
        <localStatus>IN_SERVICE</localStatus>
        <notFoundCacheActive>true</notFoundCacheActive>
        <notFoundCacheTTL>1440</notFoundCacheTTL>
        <userManaged>true</userManaged>
        <exposed>true</exposed>
        <browseable>true</browseable>
        <writePolicy>READ_ONLY</writePolicy>
        <indexable>true</indexable>
        <searchable>true</searchable>
        <localStorage>
            <provider>file</provider>
        </localStorage>
        <remoteStorage>
            <provider>apacheHttpClient3x</provider>
            <url>http://s3.amazonaws.com/maven.springframework.org/milestone/</url>
        </remoteStorage>
        <externalConfiguration>
            <repositoryPolicy>RELEASE</repositoryPolicy>
            <checksumPolicy>WARN</checksumPolicy>
            <fileTypeValidation>false</fileTypeValidation>
            <downloadRemoteIndex>true</downloadRemoteIndex>
            <artifactMaxAge>-1</artifactMaxAge>
            <metadataMaxAge>1440</metadataMaxAge>
            <autoBlockActive>true</autoBlockActive>
            <proxyMode>ALLOW</proxyMode>
        </externalConfiguration>
    </repository>
</repositories>

Shell script to quickly change environment

Shamelessly steal from work 🙂

#!/bin/bash
echo Change Versions

java4()
{
    echo "Not set up yet!!!"
    #export JRE_HOME=
    #export JDK_HOME=
    export JAVA_HOME=$JAVA5
    export PATH=$JAVA_HOME/bin:$PATH
    break
    return
}

java5()
{
    echo "Changing to Java 1.5"
    #export JRE_HOME=
    #export JDK_HOME=$JAVA5
    export JAVA_HOME=$JAVA5
    export PATH=$JAVA_HOME/bin:$PATH
    break
    return
}

java6()
{
    echo "Changing to Java 1.6"
    #export JRE_HOME=
    #export JDK_HOME=
    export JAVA_HOME=$JAVA6
    export PATH=$JAVA_HOME/bin:$PATH
    break
    return
}

maven2()
{
    echo "Changing to Maven 2"
    export M2_HOME=$TOOLS/apache-maven-2.2.1
    export PATH=$M2_HOME/bin:$PATH
    break
    return
}

maven3()
{
    echo "Changing to Maven 2"
    export M2_HOME=$TOOLS/apache-maven-3.0.2
    export PATH=$M2_HOME/bin:$PATH
    break
    return
}

print_help_uu()
{
    echo "Please select :";
    echo "Where a = Java 4";
    echo "      b = Java 5";
    echo "      c = Java 6";
    echo "      d = Maven 2";
    echo "      e = Maven 3";
    return
}

print_help_uu
 
while read opt
do
    case "$opt" in
    a) java4;;
    b) java5;;
    c) java6;;
    d) maven2;;
    e) maven3;;
    esac
done

I have JAVA5 and JAVA6 variables set in a separate file. Save this to a file i.e. version and type . version will allow you to quickly switch dev environments.

set up Android development with maven and intellij

Download android SDK and unpack it to a location (mine is ~/tools/android-sdk-linux_x86).
Set up android home environment variable. Alternatively you may consider to have an environment variable setup file to better manage all these. See this post.

export ANDROID_SDK_HOME=$HOME/tools/android-sdk-linux_x86

Set up andriod SDK

cd $ANDROID_SDK_HOME
./android

In the GUI click on Available Packages and select all the packages you want.
Click Virtual Devices and create a new android virtual device. Better name it something indicating its target android version(i.e. avd2.3.3). Adjust other settings as you wish.

Bare minimal android SDK is all done now. Next move onto maven. There is an excellent blog for all the details from the archetype author here. The simplest step will be (assuming you already have maven set up and you also prefer to have test with all your code):

mvn archetype:generate \
-DarchetypeArtifactId=android-quickstart \
-DarchetypeGroupId=de.akquinet.android.archetypes \
-DarchetypeVersion=1.0.4 \
-DgroupId=your.company \
-DartifactId=my-android-application

Watch it finishes and now you can use intellij to open the pom.xml file.
Open your Project Structrue (ctrl+alt+shift+s), select Platform Settings->SDKs and create a new Android SDK by browsing to your installed location. Back to your Project Settings->Modules, click Dependencies tab and flip Module SDK to android.

Open your android activity file (if you use the archetype then the default created one is HelloAndroidActivity.java. ctrl+shift+F10 to run it. You should see a virtual device launched and your dummy application is deployed on it. Hooray!

Note: by default it will launch the first virtual device you created. But if you have more than one and want to run your application on a different one, you can choose it from the run configurations menu.

ubuntu dev environment (intelliJ and environment variables)

Quick notes to myself and may help others.

  • Download simsun.ttf font and double click to install. Change browser font settings to use this fond. Better Chinese view.
  • Download jdk, maven, intellij and install.
  • Create a text file (I generally name it env_variable) under home directory with following content(adjust accordingly):
    export WORK=$HOME/work
    export TOOLS=$HOME/toolsexport JAVA_HOME=$TOOLS/jdk1.6.0_22
    export JDK_HOME=$JAVA_HOMEexport IDEA_HOME=$TOOLS/idea-IU-107.105
    export SCRIPTS=$HOME/scripts
    export M3_HOME=$TOOLS/apache-maven-3.0.3
    #export M2_HOME=$TOOLS/apache-maven-2.2.1
    #export ROO=$TOOLS/spring-roo-1.1.0.RELEASE
    export GROOVY_HOME=$TOOLS/groovy-1.8.2
    export NEXUS_HOME=$TOOLS/nexus-1.9.1.1
    export ANDROID_SDK_HOME=$TOOLS/android-sdk-linux_x86
    #:$ROO/bin
    PATH=$JAVA_HOME/bin:$M3_HOME/bin:$SCRIPTS:$IDEA_HOME/bin:$GROOVY_HOME/bin:$ANDROID_SDK_HOME/tools:$PATH
    
  • Open file manage (nautilus) and go to home folder, ctrl + h to show hidden files. Then open .profile file and add following line (assuming saving above created file as env_variable)
    # load environment variables
    . $HOME/env_variables
    

    The reason why we source this environment variable file in .profile is, if you want to launche intellij from your desktop GUI(gnome), it requires JDK_HOME being set. If you don’t have .bash_profile defined, both your terminal and gnome will use .profile. This way you can easily create an application launcher in gnome.

  • Right click gnome panel and select Add to Panel…, then select Custome Application Launcher, name as ‘intellj’, command browse to your intellij bin folder and select idea.sh. There are some nice icon under bin folder too for you to choose. After reboot you should be able to launch intellij from here.
  • Change file system watcher handles number. See this for more detail. If you use latest intellij you should already have those fsnotifier files under your intellij bin folder. All you need to do is execute following command in shell
    gksu gedit /etc/sysctl.conf

    add

    fs.inotify.max_user_watches = 524288

    to last line. Execute

    sudo sysctl -p

    to take effect.

  • For ubuntu 10.04 only. If you want your gnome terminal to open up with a better default size, execute
    gksu gedit /usr/share/vte/termcap/xterm

    find lines as

    xterm-xfree86|xterm-new|xterm terminal emulator (XFree86):\
    :am:km:mi:ms:xn:\
    :co#80:it#8:li#24:\

    The co#80 is the column width and li#24 is row number. I normally make column to 132.

Happy coding 🙂

Install ubuntu 10.04 on thinkpad L420

My L420 has the serial number 78544KM. There are other serial numbers available and seems like the devices are a bit different, i.e. the wireless device.

Run following command in your shell should give you what your wireless device is

lspci -nn | grep -i network

Mine is this:
03:00.0 Network controller [0280]: Intel Corporation Device [8086:0085] (rev 34)

I initially install ubuntu 10.04 LTS and the kernel version is 2.6.32-33-generic. According to this post upgrade kernel version to 2.6.36-xx will fix it. But at that time I went to the other option, installing a compact wireless driver. It worked.

There is another problem with ubuntu 10.04. The screen resolution is max at 1024*768 which isn’t the full capacity. I posted a thread in ubuntu forum and get the answer to upgrade to newer kernel version.
Here is the command to do it.

sudo add-apt-repository ppa:glasen/intel-driver
sudo add-apt-repository ppa:kernel-ppa/ppa
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install linux-image-generic-lts-backport-natty linux-headers-generic-lts-backport-natty

From the first post link, it seems like for ubuntu 10.10, you can upgrade to
linux-headers-2.6.36-1 directly without having to use a backport version from a ppa. I may give it a try if I need to reinstall my os again in the future… while unity still sucks to use…