10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I need help with one of my shell script. The script is working fine but i need to add two condition -
i need to get rid of all the below ftp messages and need to have only ftp completed or failed message.
example when i run the script i get below lines -
Connected to xxxx
220 (vsFTPd... (1 Reply)
Discussion started by: chandraprakash
1 Replies
2. Shell Programming and Scripting
Hi everyone,
I have been using a shell script for the last 6 months to copy a database from a POS system, then analyse the database and print the current sales total. This has worked flawlessly, the only issue was that I had hard coded the IP address of the POS and occasionally I would need to... (23 Replies)
Discussion started by: gjws
23 Replies
3. Shell Programming and Scripting
a=1
b1=unix
echo $b`$a`
The above code is not working. Instead of printing the variable b1 using 'echo $b1', how to use variable 'a' to print 'b1' (1 Reply)
Discussion started by: thulasidharan2k
1 Replies
4. Shell Programming and Scripting
For example I have variable like below
echo $OUTPUT
/some/path/`uname -n`
when I try to use the variable OUTPUT like below
cd $OUTPUT or cd ${OUTPUT}
I am getting bad substituion error message
$ cd $OUTPUT
ksh: cd: bad substitution
$ cd ${OUTPUT}
ksh: cd: bad substitution
... (1 Reply)
Discussion started by: rajukv
1 Replies
5. Shell Programming and Scripting
Hello All,
I would like to create a script to echo a text where a (.) dot is added every 2 seconds to the end of this text (with a limit of 10 dots) as long as a file copy or ftp is ongoing and once the copy is finished it adds "done" to the end of this text line. please see the below example:
... (6 Replies)
Discussion started by: Dendany83
6 Replies
6. Shell Programming and Scripting
Hi,
I am generating html code using cshell, but i am having one problem while printing double quotes,
I need to write following code in file. where $var contains list of web address
<a href="$var">$var</a>
So i am using
echo "<a href="$var">$var</a>" > file.html
But with this " in... (4 Replies)
Discussion started by: sarbjit
4 Replies
7. Shell Programming and Scripting
Hi ,
I have a variable as follows,
Temp=`cat ABC.txt | cut -c5-`
This will yeild a part of the date. say , 200912.
I would like to substitute this variable's value in a filename.
eg: File200912F.zip
when i say File$TempF.zip , it is not substituting.
Any help ?
Thanks in... (2 Replies)
Discussion started by: mohanpadamata
2 Replies
8. UNIX for Dummies Questions & Answers
I'm trying to get this to work and I'm not really sure how to do it.
echo $x | awk '{print $NF}' MODIFIEDThe output I'm trying to get should look like:
dir1 MODIFIED
Where dir1 will be the result of:
$x |awk '{print $NF}'I'm sure there's something I'm supposed to put around that part... (3 Replies)
Discussion started by: ewoods
3 Replies
9. Shell Programming and Scripting
Hello,
i have another sed question.. I'm trying to do variable substition with sed and i'm running into a problem.
my var1 is a string constructed like this:
filename1 filerev1 filepath1
my var2 is another string constructed like this:
filename2 filerev2 filepath2
when i do... (2 Replies)
Discussion started by: alrinno
2 Replies
10. UNIX for Dummies Questions & Answers
Hi everyone,
I have a simple question to ask :
In a script that I'm writting, I need to create variables on-the-fly.
For instance, for every iterartion of the following loop a var_X variable should be generated :
#!/bin/ksh
a="1 2 3"
for i in $a
do
var_${i}=$i
echo "${var_$i}"
done
... (1 Reply)
Discussion started by: ck-18
1 Replies