#!/bin/sh # # List jails # Usage: list # set -eu # shellcheck source=./includes LIBDIR="$(dirname $0)" && . "${LIBDIR}/includes" [ -d "${JAILDIR}" ] || exit 0 #TODO: try if this command works the same : # find "${JAILDIR}" -mindepth 1 -maxdepth 1 -type d -printf '%f\n' find "${JAILDIR}" -mindepth 1 -maxdepth 1 -type d|sed 's!.*/!!'