Skip to content
This repository has been archived by the owner on Apr 23, 2024. It is now read-only.

Building

lhazlewood edited this page Mar 10, 2012 · 2 revisions

The Logback Extensions project is built with Maven, version 2.2.1 or later (3.x works fine). After ensuring maven is installed and working properly, you build via the following command in the root of the project directory:

mvn install

Deploying Artifacts

mvn install will build and store the built .jar files on your local disk only. To be available to others, they must be uploaded to a publicly accessible repository.

Your Own Repository

If you would like to build and deploy Logback Extensions to your own public repository, you may do the following:

  1. Open your $HOME/.m2/settings.xml file for editing. See the Maven Settings Reference if you don't know what this file is or don't yet have one.
  2. Add a new profile to the profiles section:
     <profiles>
         ...
         <profile>
             <id>logback-extensions</id>
             <properties>
                 <logback-extensions.repository.releases.url>YOUR_RELEASE_URL_HERE</logback-extensions.repository.releases.url>
                 <logback-extensions.repository.snapshots.url>YOUR_SNAPSHOT_URL_HERE</logback-extensions.repository.snapshots.url>
             </properties>
         </profile>
     </profiles>
     
  3. Ensure this new profile is in your activeProfiles section:
     <activeProfiles>
         ...
         <activeProfile>logback-extensions</activeProfile>
     </activeProfiles>
     
  4. Add two new server entries to the servers section:
     <servers>
         ...
         <server>
             <id>logback-extensions.repository.releases</id>
             <username>YOUR_USERNAME_FOR_THE_ABOVE_RELEASES_URL</username>
             <password>YOUR_PASSWORD_FOR_THE_ABOVE_RELEASES_URL</password>
         </server>
         <server>
             <id>logback-extensions.repository.snapshots</id>
             <username>YOUR_USERNAME_FOR_THE_ABOVE_SNAPSHOTS_URL</username>
             <password>YOUR_PASSWORD_FOR_THE_ABOVE_SNAPSHOTS_URL</password>
         </server>
     </servers>
     
  5. Save and exit the file.

Now when you run mvn deploy at the root of the project, the build will deploy the artifacts to the repositories you specified.

Clone this wiki locally