Skip to content

Instantly share code, notes, and snippets.

@gabikat
Created August 2, 2021 16:31
Show Gist options
  • Save gabikat/780627d267c669cf4c681d199b5ab25b to your computer and use it in GitHub Desktop.
Save gabikat/780627d267c669cf4c681d199b5ab25b to your computer and use it in GitHub Desktop.
Simple bash script to copy specific files or directories into another directory
# retrieves all directories from subs2 ending in -T2398 to copy into the directory 'subs'
for f in subs2/*-T2398
do
cp -r $f subs
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment