Install on Linux

To use the Polylith tool and to get access to all the features in tools.deps, make sure you have CLI tools and git installed. If you install git for the first time, don't forget to set the user name and email.
To install the poly command on Linux:
  • Download the latest release of the poly jar,
    e.g. poly-0.2.17-alpha.jar.
  • Create a directory, e.g. /usr/local/polylith and copy the jar file to that directory.
  • Create a file with the name poly and put it in e.g. /usr/local/bin with this content:
    while [ "$1" != "" ] ; do
    ARGS="$ARGS $1"
    exec "/usr/bin/java" $JVM_OPTS "-jar" "/usr/local/polylith/poly-0.2.17-alpha.jar" $ARGS
  • Make sure that:
    • you point to the correct jar file.
    • the path to java is correct (can be verified with which java).
  • If you choose /usr/local/bin, it was probably already on your path, otherwise you have to add it.
  • Make it executable by executing chmod +x poly.
Verify the installation by executing poly help.