Skip to content

Instantly share code, notes, and snippets.

@abdul
Created September 16, 2016 17:35
Show Gist options
  • Save abdul/4fea40dfdd8049dda6a8a7b253a6a0aa to your computer and use it in GitHub Desktop.
Save abdul/4fea40dfdd8049dda6a8a7b253a6a0aa to your computer and use it in GitHub Desktop.
Run Bash command on all files in a directory
for file in /Users/xyz/Desktop/my-dir/*; do echo "hello $file" >> results.out; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment