/java-utilities

Simple Java utilities

Primary LanguagePythonApache License 2.0Apache-2.0

java-utilities

java-utilities provides a very small utilities.jar (<1KiB) for simple Java programs.

It has zero dependencies.

Simple stdout for easy integration with other tools / languages.

Works with Java 8+.

Programs

Lookup Property

The lookup property program allows the caller to lookup a single property name.

java -cp utilities.jar LookupProperty <property.name>

This allows a more robust way to determine java.home as compared to following symlinks from /usr/bin/java, or the more more fragile approach:

java -XshowSettings:properties -version 2>&1 \
    | grep "java.home" \
    | awk -F " = " '{print $2}'

Python Integration

The java-utilities PyPi package provides java-utilities as a Python library.

See README-pypi.md for more information.

JAR

The utilities.jar is checked into the repository (as opposed to uploaded to Maven Central) as it is unlikely to be depended on as a Java library.