Skip to content

Instantly share code, notes, and snippets.

@theagoliveira
Created April 15, 2021 06:24
Show Gist options
  • Save theagoliveira/2a4cfc65d0ce5faa4fe6a49b1120a0f6 to your computer and use it in GitHub Desktop.
Save theagoliveira/2a4cfc65d0ce5faa4fe6a49b1120a0f6 to your computer and use it in GitHub Desktop.
Recursively iterate through files in a directory
# SOURCE: https://unix.stackexchange.com/a/139381/454027
while IFS= read -r -d '' -u 9
do
echo "Filename is '$REPLY'"
done 9< <( find "PATH" -regex ".*\.EXTENSION" -exec printf '%s\0' {} + )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment