Why ?
To
run on command or execute the same file in different directory you will need to
do this whether using a find command or with shell script to be in more flexible
.
How ?
This
is a shell script file :
1- create a shell file(example):
vim check_file.sh
2- sample of for loop to execute "file.sh" and echo command in multiple directories (dir1,
dir2, dir3 , dir4) :
#!/bin/sh
for dir in /path/dir*; do
echo
$dir
$dir/file.sh
done;
No comments:
Post a Comment