#!/usr/bin/env bash # Make sure the current directory is the location of this script to simplify matters cd "$(dirname "$(readlink -f "$0")")"; find hosts -type f -iname '*.txt' | xargs -n1 basename --suffix=.txt | sort