pax_global_header 0000666 0000000 0000000 00000000064 12534045214 0014512 g ustar 00root root 0000000 0000000 52 comment=0ae17d4999f712685088b44587c83df93a945294
osmosis-0.44.1/ 0000775 0000000 0000000 00000000000 12534045214 0013274 5 ustar 00root root 0000000 0000000 osmosis-0.44.1/.gitignore 0000664 0000000 0000000 00000000052 12534045214 0015261 0 ustar 00root root 0000000 0000000 .gradle
*.javaEe
*.javae
*.iml
*.ipr
*.iws osmosis-0.44.1/README 0000664 0000000 0000000 00000004137 12534045214 0014161 0 ustar 00root root 0000000 0000000 Osmosis is a command line Java application for processing Open Street Map
(http://www.openstreetmap.org) data.
The tool consists of a series of pluggable components that can be chained
together to perform a larger operation. For example, it has components for
reading from database and from file, components for writing to database and to
file, components for deriving and applying change sets to data sources,
components for sorting data, etc. It has been written so that it is easy to add
new features without re-writing common tasks such as file or database handling.
Some brief build, running and installation notes are provided below, however
most documentation may be found on the project wiki page.
http://wiki.openstreetmap.org/wiki/Osmosis
**** BUILD ****
Osmosis is built using the Gradle (http://gradle.org) built tool, however
Gradle does not need to be installed. The only requirements are a 1.6 JDK, and
an Internet connection.
Below are several commands useful to build the software. All commands must be
run from the root of the source tree.
Build the software without running unit tests:
./gradlew assemble
Perform a complete build including unit tests:
./gradlew build
Clean the build tree:
./gradlew clean
Verify checkstyle compliance:
./gradlew checkstyleMain checkstyleTest
**** RUNNING ****
After completing the build process, a working Osmosis installation is contained
in the package sub-directory. The Osmosis launcher scripts reside in the bin
sub-directory of package. On a UNIX-like environment use the "osmosis" script,
on a Windows environment use the "osmosis.bat" script.
However, for installing the software it is recommended to use a distribution
archive described below.
**** INSTALLATION ****
After completing the build process, distribution archives in zip and tar gzipped
formats are contained in the package/build/distribution directory. These
archives may be extracted to a location of your choice. The bin sub-directory
should either be added to your PATH, or in the case of UNIX-like environments
the "osmosis" script may be symlinked into an existing directory already on the
PATH.
osmosis-0.44.1/build-support/ 0000775 0000000 0000000 00000000000 12534045214 0016105 5 ustar 00root root 0000000 0000000 osmosis-0.44.1/build-support/.gitignore 0000664 0000000 0000000 00000000017 12534045214 0020073 0 ustar 00root root 0000000 0000000 .project
/ivy
osmosis-0.44.1/build-support/checkstyle.xml 0000664 0000000 0000000 00000014505 12534045214 0020772 0 ustar 00root root 0000000 0000000
osmosis-0.44.1/build-support/osmosis_formatting.xml 0000664 0000000 0000000 00000067550 12534045214 0022572 0 ustar 00root root 0000000 0000000
osmosis-0.44.1/build.gradle 0000664 0000000 0000000 00000007616 12534045214 0015565 0 ustar 00root root 0000000 0000000 task wrapper(type: Wrapper) {
gradleVersion = '2.4'
}
apply plugin: 'idea'
/* Build collections containing each type of project. These collections will
* be used to apply common configurations to projects of the same type.
*/
def packageProjects = allprojects.findAll { project -> project.path.equals(':package') }
def buildProjects = allprojects.findAll { project -> project.path.equals(':build-support') }
def dockerProjects = allprojects.findAll { project -> project.path.equals(':db-server') }
// Java projects are all those that aren't in the previous collections.
def javaProjects = subprojects.findAll { project -> !packageProjects.contains(project) && !buildProjects.contains(project) && !dockerProjects.contains(project) }
// Apply common project configuration
subprojects {
apply plugin: 'eclipse-wtp'
apply plugin: 'idea'
// All projects use a common group id.
group = 'org.openstreetmap.osmosis'
// Load the project version dynamically from Git. For release builds, don't add a suffix.
def versionSuffix = "RELEASE".equals(osmosisBuildType) ? '' : '-' + osmosisBuildType
version = 'git describe --always --dirty'.execute().in.text.trim() + versionSuffix
// Enable access to artefact dependency repositories.
repositories {
// Standard Maven repository.
mavenCentral()
}
}
// Apply common configurations to all projects supporting Java.
configure(javaProjects) {
apply plugin: 'checkstyle'
apply plugin: 'java'
apply plugin: 'jdepend'
apply plugin: 'maven'
apply plugin: 'signing'
sourceCompatibility = 1.6
test {
/*
* Pass on each of our custom properties to the unit tests if they have
* been provided.
*/
['db.apidb.authfile', 'db.pgsql.authfile'].each {
propName ->
if (System.getProperties().containsKey(propName)) {
jvmArgs '-D' + propName + '=' + System.getProperty(propName)
}
}
//testLogging.showStandardStreams = true
}
dependencies {
testCompile group: 'junit', name: 'junit', version: dependencyVersionJunit
}
checkstyle {
configFile = new File(rootDir, 'build-support/checkstyle.xml')
configProperties.samedir = configFile.parentFile
}
// Build javadoc and source jars and include in published artifacts.
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from 'build/docs/javadoc'
}
task sourcesJar(type: Jar) {
from sourceSets.main.allSource
classifier = 'sources'
}
artifacts {
archives jar
archives javadocJar
archives sourcesJar
}
// Sign all published artifacts if signing is enabled.
signing {
sign configurations.archives
required = Boolean.valueOf(osmosisSigningEnabled)
}
// Configure the maven plugin to upload artefacts to the Sonatype repository.
uploadArchives {
repositories {
mavenDeployer {
beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) }
// We upload to the Sonatype SNAPSHOT repository unless it is a release build in
// which case we upload to the staging repository.
def sonatypeRepoUrl = "RELEASE".equals(osmosisBuildType) ?
'https://oss.sonatype.org/service/local/staging/deploy/maven2/' :
'https://oss.sonatype.org/content/repositories/snapshots/'
repository(url: sonatypeRepoUrl) {
authentication(userName: sonatypeUsername, password: sonatypePassword)
}
pom.project {
name project.name
packaging 'jar'
description 'Osmosis is a Java application and library for processing OSM data.'
url 'http://wiki.openstreetmap.org/wiki/Osmosis'
scm {
url 'https://github.com/openstreetmap/osmosis'
connection 'scm:git:git://github.com/openstreetmap/osmosis.git'
developerConnection 'scm:git:ssh://git@github.com/openstreetmap/osmosis.git'
}
licenses {
license {
name 'Public Domain'
}
}
developers {
developer {
id 'brett'
name 'Brett Henderson'
email 'brett@bretth.com'
}
}
}
}
}
}
}
osmosis-0.44.1/db-server/ 0000775 0000000 0000000 00000000000 12534045214 0015165 5 ustar 00root root 0000000 0000000 osmosis-0.44.1/db-server/.gitignore 0000664 0000000 0000000 00000000037 12534045214 0017155 0 ustar 00root root 0000000 0000000 .classpath
.project
.settings
osmosis-0.44.1/db-server/Dockerfile 0000664 0000000 0000000 00000000347 12534045214 0017163 0 ustar 00root root 0000000 0000000 FROM fedora:21
# Install PostgreSQL
RUN yum install -y postgresql-server postgresql-contrib
# Install PostGIS
RUN yum install -y postgis
EXPOSE 5432
COPY docker-start.sh /start.sh
COPY script /install/script
CMD ["/start.sh"]
osmosis-0.44.1/db-server/build.sh 0000775 0000000 0000000 00000000430 12534045214 0016620 0 ustar 00root root 0000000 0000000 #!/bin/sh
# Build the docker image.
# The use of tar is a workaround for the docker restriction of not following symlinks. This
# tar command dereferences symlinks and then passes the resultant archive to the docker build.
tar -czh . | docker build -t="bretth/osmosis-build" -
osmosis-0.44.1/db-server/docker-start.sh 0000775 0000000 0000000 00000004103 12534045214 0020124 0 ustar 00root root 0000000 0000000 #!/bin/bash
DATADIR="/var/lib/pgsql/data"
# test if DATADIR has content
if [ ! "$(ls -A $DATADIR)" ]; then
# Create the en_US.UTF-8 locale. We need UTF-8 support in the database.
localedef -v -c -i en_US -f UTF-8 en_US.UTF-8
echo "Initializing Postgres Database at $DATADIR"
su postgres sh -lc "initdb --encoding=UTF-8 --locale=en_US.UTF-8"
su postgres sh -lc "postgres --single -jE" <<-EOSQL
CREATE USER osm WITH SUPERUSER PASSWORD 'password';
EOSQL
# Allow the osm user to connect remotely with a password.
echo "listen_addresses = '*'" >> "${DATADIR}/postgresql.conf"
echo "host all osm 0.0.0.0/0 md5" >> "${DATADIR}/pg_hba.conf"
# Create the pgsnapshot database owned by osm.
su postgres sh -lc "postgres --single -jE" <<-EOSQL
CREATE DATABASE pgosmsnap06_test OWNER osm;
EOSQL
# Create the apidb database owned by osm.
su postgres sh -lc "postgres --single -jE" <<-EOSQL
CREATE DATABASE api06_test OWNER osm;
EOSQL
# Start the database server temporarily while we configure the databases.
su postgres sh -lc "pg_ctl -w start"
# Configure the pgosmsnap06_test database as the OSM user.
su postgres sh -lc "psql -U osm pgosmsnap06_test" <<-EOSQL
CREATE EXTENSION hstore;
CREATE EXTENSION postgis;
\i /install/script/pgsnapshot_schema_0.6.sql
\i /install/script/pgsnapshot_schema_0.6_action.sql
\i /install/script/pgsnapshot_schema_0.6_bbox.sql
\i /install/script/pgsnapshot_schema_0.6_linestring.sql
EOSQL
# Configure the api06_test database as the OSM user.
su postgres sh -lc "psql -U osm api06_test" <<-EOSQL
\i /install/script/contrib/apidb_0.6.sql
\i /install/script/contrib/apidb_0.6_osmosis_xid_indexing.sql
EOSQL
# Stop the database.
su postgres sh -lc "pg_ctl -w stop"
fi
SHUTDOWN_COMMAND="echo \"Shutting down postgres\"; su postgres sh -lc \"pg_ctl -w stop\""
trap "${SHUTDOWN_COMMAND}" SIGTERM
trap "${SHUTDOWN_COMMAND}" SIGINT
# Start the database server.
su postgres sh -lc "pg_ctl -w start"
echo "Docker container startup complete"
# Wait for the server to exit.
while test -e "/var/lib/pgsql/data/postmaster.pid"; do
sleep 0.5
done
osmosis-0.44.1/db-server/readme.txt 0000664 0000000 0000000 00000001230 12534045214 0017157 0 ustar 00root root 0000000 0000000 This directory contains the scripts to create a docker-based database server to be used for unit testing.
In order to use this server, docker must be installed on the local workstation. Beyond that, no additional
configuration should be required.
To build the docker image, run the following script.
./build.sh
To run the docker image, run the following command. To stop the server, press Ctrl-C.
docker run -ti --rm=true --name osmosis-build -p 5432:5432 bretth/osmosis-build
If you wish to troubleshoot a running server, you may run the following command to get a bash prompt
inside the docker container.
docker exec -ti osmosis-build /bin/bash
osmosis-0.44.1/db-server/script 0000777 0000000 0000000 00000000000 12534045214 0021444 2../package/script ustar 00root root 0000000 0000000 osmosis-0.44.1/gradle.properties 0000664 0000000 0000000 00000004005 12534045214 0016647 0 ustar 00root root 0000000 0000000 # Enable the gradle build daemon. The daemon is a gradle process that
# remains running between builds. This significantly speeds up build
# times.
org.gradle.daemon=true
# 3rd Party Library Versions
dependencyVersionClassworlds=2.5.2
dependencyVersionCommonsCodec=1.10
dependencyVersionCommonsCompress=1.9
dependencyVersionCommonsDbcp=1.4
dependencyVersionJpf=1.5
dependencyVersionJunit=4.12
dependencyVersionMySql=5.1.35
dependencyVersionNetty=3.2.10.Final
dependencyVersionPostGis=1.3.3
dependencyVersionPostgreSql=9.4-1201-jdbc4
dependencyVersionProtobuf=2.6.1
dependencyVersionSpring=4.1.6.RELEASE
dependencyVersionWoodstoxCore=4.4.1
dependencyVersionWoodstoxStax2=3.1.4
# Remaining on 2.9.1 instead of 2.10.0 for now because the newer version
# depends on org.w3c.dom.ElementTraversal which is not being transitively
# included. This could be possibly be fixed by including a newer version
# of xml-apis but this hasn't been verified.
dependencyVersionXerces=2.9.1
# Builds are signed if the osmosisSigningEnabled property is set to true.
# To enable signing, it is recommended to leave this file untouched and to
# create a gradle.properties in your /.gradle/ directory and override
# the setting there. It is also necessary to set the following properties:
# * signing.keyId - Something like ABCDEFGH (see gpg --list-keys)
# * signing.secretKeyRingFile - Something like /home//.gnupg/secring.gpg
# * signing.password - The password to unlock the secret key.
osmosisSigningEnabled=false
# If uploading to the Sonatype repositories, a username/password must be
# provided. To do this, create a gradle.properties in your /.gradle/
# directory and override the below property values there.
sonatypeUsername=DO NOT EDIT ME. Read the above comments.
sonatypePassword=DO NOT EDIT ME. Read the above comments.
# By default, all builds are SNAPSHOT builds. To create a release build, this
# property should be overridden to be RELEASE. Note that this variable should
# not be updated.
osmosisBuildType=SNAPSHOT
osmosis-0.44.1/gradle/ 0000775 0000000 0000000 00000000000 12534045214 0014532 5 ustar 00root root 0000000 0000000 osmosis-0.44.1/gradle/wrapper/ 0000775 0000000 0000000 00000000000 12534045214 0016212 5 ustar 00root root 0000000 0000000 osmosis-0.44.1/gradle/wrapper/gradle-wrapper.jar 0000664 0000000 0000000 00000146052 12534045214 0021634 0 ustar 00root root 0000000 0000000 PK
`QF META-INF/ PK
`QFr+? T META-INF/MANIFEST.MFMLK-.
K-*ϳR03-IM+I,
dZ)%bµrr PK
]QF org/ PK
]QF org/gradle/ PK
]QF org/gradle/wrapper/ PK
]QFhdf # org/gradle/wrapper/Download$1.class}M
0h5Z+v/׆p!.