Skip to content

eXist-book/book-code

Repository files navigation

eXist Book Example Code

Build Status Java 7 License

This repository contains all (except the Using eXist 101 chapter) of the code and examples discussed in the eXist book published by O'Reilly.

This version contains code compatible with eXist-db 2.1 which was the latest version at the time the book was authored. Versions for eXist-db 3.0.RC1, 3.0, and 4.0.0 are also available.

The repository has the following layout:

  • chapters/ Under this folder each chapter of the book that has example code is represented.

  • xml-examples-xar/ These are the files needed to build an EXPath Package XAR from other files distributed in the chapters folders. In particular the content of the XAR package is assembled using the the fileSets set out in the assembly xml-examples-xar/expath-pkg.assembly.xml

All other files are related to the Maven build process.

Building

The EXPath Package XAR and the Java projects are all built using Apache Maven. You will need to have Git and at least Maven 3.1.1 installed. Git can be downloaded and installed from http://git-scm.com and you can download and install Maven from http://maven.apache.org.

Once you have Maven installed you can simply run the following from your Unix/Linux/Mac terminal or Windows command prompt:

git clone https://github.com/eXist-book/book-code.git
cd book-code
mvn clean install

You should then find the EXPath PKG XAR located at xml-examples-xar/target/exist-book.xar. The Java projects artifacts will be located within the target sub-folders of each Java project respectively.