Installation instructions - Georgetown-University-Libraries/File-Analyzer GitHub Wiki

Pre-requisites

  • Java SE JDK 1.7 or higher (for build). If you do not already had the JDK installed, install the most recent version.
  • Apache Maven (or you will need to compile the modules manually)

Runtime pre-requisites (when deploying the File Analyzer for use by others)

  • Java SE JRE 1.7 or higher (for runtime, the JRE is included with the JDK). If your users do not already had the JRE installed, install the most recent version.

Installation

  1. Clone this GitHub repository to your computer

  2. Open a command window/shell window and cd to the directory where the project is installed

    C:\Users\yourid\Documents\GitHub\File-Analyzer>

  3. Run mvn install from the root directory

    C:\Users\yourid\Documents\GitHub\File-Analyzer>mvn install

Maven will compile your code and it will download open source dependencies for the project. Maven will generate a good deal of output. When maven is complete, you should see something like the following.

----------------------------------------------------------------------- 
Reactor Summary:

FileAnalyzer ...................................... SUCCESS [0.486s]
CoreFileAnalyzer .................................. SUCCESS [1.680s]
DSpaceFileAnalyzer ................................ SUCCESS [1.005s]
DemoFileAnalyzer .................................. SUCCESS [5.849s]
-----------------------------------------------------------------------
BUILD SUCCESS

Maven builds have a default convention when building resources. Code that is built for a project will end up in the target directory for theproject.

Check the contents of the core/target directory.

  • This directory will contain a the file CoreFileAnalyzer-2.0.jar.
  • This file is a self-extracting jar file. Launch this file to run the most basic form of the File Analyzer.

Check the contents of the demo/target directory

  • There are several jar files in this directory because this project includes Apache Tika and BagIt.
  • This directory will contain the file DemoFileAnalyzer-2.0.jar
  • This file is a self-extracting jar file containing with dependencies on all of the other jar files in the directory.
  • Launch this file to run a more customized version of the File Analyzer.
  • Note: when moving this file to another location, be certain to move the other jar files along with it.

Eclipse Configuration

  1. Run maven install locally to download the appropriate version of Apache Tika and BagIt

  2. Create a Java project

  3. Each FileAnalyzer package will be in its own source folder

     <classpath>
         <classpathentry kind="src" path="demo/src/main"/>
         <classpathentry kind="src" path="dspace/src/main"/>
         <classpathentry kind="src" path="core/src/main"/>
         <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
         <classpathentry kind="lib" path="C:/Users/yourid/.m2/repository/gov/loc/bagit/4.8/bagit-4.8.jar"/>
         <classpathentry kind="lib" path="C:/Users/yourid/.m2/repository/org/apache/tika/tika-app/1.4/tika-app-1.4.jar"/>
         <classpathentry kind="output" path="bin"/>`
     </classpath>
    

Deployments

This code will build 3 flavors of the File Analyzer.

1. Core File Analyzer

All code runs from a self-extracting jar file

2. DSpace File Analyzer

This version of the file analyzer is a self-extracting jar file that references the core file analyzer jar file.

It contains tools for automating the creation of DSpace ingestion folders

3. Demo File Analyzer

This version contains extensions illustrating various capabilities of the File Analyzer.

This version of the file analyzer is a self-extracting jar file that references both the core and dspace file analyzer jar files.

This version of the application uses features of Apache Tika and BagIt

⚠️ **GitHub.com Fallback** ⚠️