Search Results

Showing results 1 to 6 of 6
Search took 0.01 seconds.
Search: Posts Made By: jim mcnamara ; Forum: Shell Scripting and child forums
Forum: Shell Scripting Sep 15th, 2006
Replies: 6
Views: 6,042
Posted By jim mcnamara
I changed it so awk puts it all on the same line.
Forum: Shell Scripting Sep 12th, 2006
Replies: 6
Views: 6,042
Posted By jim mcnamara
I'd use arrays:

#!/bin/ksh
optfile=filename
set -A opts $(awk 'BEGIN {FS="="} { if($0~ / page_size/) { print $2}}' $optfile)
for i in 0 1 2
do
echo ${opts[i]}
done
Forum: Shell Scripting Sep 11th, 2006
Replies: 9
Views: 7,209
Posted By jim mcnamara
#!/bin/bash
# we want to copy from path1 to path2
# step 1 make all the subdirectories
find /path1 -type d | \
while read dir
do
mkdir /path2"${dir#/path1}"
done
# step 2 cp the files...
Forum: Shell Scripting Sep 8th, 2006
Replies: 4
Views: 1,748
Posted By jim mcnamara
In that case you have to use cp. mv does not mv over mount points.
Forum: Shell Scripting Aug 3rd, 2006
Replies: 2
Views: 2,432
Posted By jim mcnamara
Your logic doesn't make any sense to me...

You want to get to the "got it" statement - this does it.

#!bin/ksh
a=5
while [[ $a -gt 5 ]]
do
echo "a=5 and not went to else cdn."
Forum: Shell Scripting Jun 29th, 2006
Replies: 5
Views: 8,994
Posted By jim mcnamara
Here is a start - you need to read up on shell scripting


#!/bin/ksh

# function gen_data
# record performance data, place in a file with each node's
# information all on one line...
Showing results 1 to 6 of 6

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC