Skip to content

Instantly share code, notes, and snippets.

@was0107
Created December 30, 2016 06:36
Show Gist options
  • Save was0107/7aa6994cc1b77444df9ae2acffb38d05 to your computer and use it in GitHub Desktop.
Save was0107/7aa6994cc1b77444df9ae2acffb38d05 to your computer and use it in GitHub Desktop.
#!bin/bash
WORK_PATH="$PWD"
function list() {
SAVEIFS=$IFS
IFS=$'\n'
for file in $1/*
do
echo $file
if [[ -d "$file" ]] ; then
cd $file
sh master.sh
echo 'sleep 1 seconds'
sleep 1
fi
done
IFS=$SAVEIFS
}
list "$WORK_PATH"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment