Search Results

Search: Posts Made By: bash-o-logist
1,489
Posted By bash-o-logist
#!/bin/bash #tested with bash 4 ...
#!/bin/bash
#tested with bash 4

content=$(<file)
while [[ $content =~ Elapsed ]]
do
c=${content#*Elapsed}
case "${content%%Elapsed*}" in
*SQL*ERROR*)
echo...
1,824
Posted By bash-o-logist
while read a b c; do echo $a; done <file
while read a b c; do echo $a; done <file
8,265
Posted By bash-o-logist
#!/bin/bash # tested on bash 4 shopt -s...
#!/bin/bash
# tested on bash 4
shopt -s globstar
shopt -s nullglob
numfiles=0
for files in **/*.xls
do
cp -p "$files" /destination
((numfiles++))
done
echo $numfiles
2,372
Posted By bash-o-logist
declare -i toggle=0 while read -r line do ...
declare -i toggle=0
while read -r line
do
case "$line" in
*Reference_Data*) toggle=1;;
esac
done < file
if [ $toggle -eq 0 ] ;then
echo "Not found"
else
echo "Found"
fi
Showing results 1 to 4 of 4

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