Search Results

Search: Posts Made By: MadeInGermany
5,841
Posted By MadeInGermany
Your last sample can be written as #!/bin/bash ...
Your last sample can be written as
#!/bin/bash
LOG_DIRS="/Sandbox/logs1 /Sandbox/logs2 /Sandbox/logs3 /Sandbox/logs4"
for log_dir in $LOG_DIRS
do
for file in "$log_dir"/*
do
# ensure...
5,841
Posted By MadeInGermany
You don't need an array here. ...
You don't need an array here.
LOG_FILES="/Sandbox/logs1/* /Sandbox/logs2/* /Sandbox/logs3/* /Sandbox/logs4/*"
for file in $LOG_FILES
do
...

Or go for one more loop....
Showing results 1 to 2 of 2

 
All times are GMT -4. The time now is 10:29 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy