10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
lets say I am printing something out
echo "Please enter a valid username"
and its being printed out 5 times, is there any way I can limit to only being displayed ONCE. I tried echo -n but that just makes everything fit on one line.
Right now it keeps saying
Please enter a valid... (5 Replies)
Discussion started by: subway69
5 Replies
2. Shell Programming and Scripting
#!/bin/bash
varA="AAA1"
varB="BBB2"
varC="CCC3"
for proccx in $varA $varB $varC
do
echo "the current name is ????? , the value is $proccx"
echo " "
done
#end of script
I want the output to look something like this:
the current name is varA, the value is AAA1
the current name is... (5 Replies)
Discussion started by: ajp7701
5 Replies
3. Homework & Coursework Questions
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
What single command line would you enter to get the following output?
8140 drwxr-xr-x 9 root bin 18 Jan 20... (6 Replies)
Discussion started by: dasboot
6 Replies
4. UNIX for Dummies Questions & Answers
I've testing the following code:
echo test.txt | cut -d . -f1and get the output "text"
So why can't i assign the command to a variable?
VAR='"echo test.txt | cut -d . -f1"'
echo $VAR (5 Replies)
Discussion started by: jl487
5 Replies
5. Shell Programming and Scripting
Hi All,
I want to display content on command promt and also write in file.
For that iI ahve to write two sentence
echo "XXXXXXX"
echo "XXXXXXXX" >> 1.txt
Is there any way to write in one echo statement (1 Reply)
Discussion started by: vivek1489
1 Replies
6. Shell Programming and Scripting
Hi
I am facing a strange problem
a=03
echo ${a}
the output is 3
But i want to display it is 03
Can you people help me how to display it like 03.
Thanks (2 Replies)
Discussion started by: aishsimplesweet
2 Replies
7. Shell Programming and Scripting
Dear Friends,
I have my command output which displays on one row and values are now scrollable (vertical) 3 pages. How do i display those output in three column so that i no need to scroll?
Example:
dcadd$cat components
1.Caluculator
2.Diary
...
...
50.Mobile
51.Battery
..
...... (12 Replies)
Discussion started by: baluchen
12 Replies
8. Shell Programming and Scripting
whats the value stored in $$ (2 Replies)
Discussion started by: suri
2 Replies
9. Shell Programming and Scripting
I am modifying an existing script and it has the following line:
export SomeEnvVar=`echo ${SomeLocalVar}`
Why wouldn't it just read:
export SomeEnvVar=${SomeLocalVar}
Is there some reason to use echo instead of a direct assignment? :confused: (2 Replies)
Discussion started by: shellburger
2 Replies
10. Shell Programming and Scripting
Hi,
My script prints a few varibales as each it reads each line of a text file and then prints them on screen, however iam having problem in aligning and sorting them.
what happens is this
Last First Number
Mark leo 87798798... (1 Reply)
Discussion started by: shackman66
1 Replies