10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have a script in tcsh and I want to have a find option to which I can pass a file search pattern I want using the command:
/home/chrisd/tatsh/trunk/hstmy/bin/tcsh/raytrac.tcsh -f=*rc*
The set command seems to fail when user does not supply a search pattern (if user just supplies -f, a... (2 Replies)
Discussion started by: kristinu
2 Replies
2. UNIX for Advanced & Expert Users
Hi All,
I am running the script
VBoxManage list vms |sed 's/"//g' | cut -d " " -f1 > har1out.mytxt
result=`cat har1out.mytxt | grep $1'
echo $result
echo $1
{
if
then
echo pass
else
echo fail
fi (2 Replies)
Discussion started by: harsha85
2 Replies
3. Shell Programming and Scripting
Hi friends,
I am very new to Unix scripting and having some difficulty in my first shell script.
I have written a simple shell script to upload an artifact to a remote machine on the network.
echo "Uploading the artifact"
scp app.war username@remotemochine.domainname.net:/home/deployables... (3 Replies)
Discussion started by: prashdeep
3 Replies
4. Shell Programming and Scripting
Hi I am trying to get my script to accept input regardless if the person enters a or A. here is the portion of the code where I get the input.
echo -n 'Please enter your choice:' # prompt user for input.
read reply # read input
echo
case $reply in #... (2 Replies)
Discussion started by: DualPandas
2 Replies
5. Shell Programming and Scripting
If ($argv == “-debug”) then
Echo “in loop”
Endif
But this is not working. If I modify this code and remove “-“, then it works.
Similarly I am getting problem using grep command also
Grep “-debug” Filename
Can someone please help me on how to resolve these... (1 Reply)
Discussion started by: sarbjit
1 Replies
6. Shell Programming and Scripting
Is there a way accept A-Za-z0-9 from the user from a parameter?
EX. I want to take the parameter from the user even if its hEu or H3y
and store it as a parameter ( $1 ) (18 Replies)
Discussion started by: puttster
18 Replies
7. UNIX for Dummies Questions & Answers
I how do i accept a input date in script which is lesser than a specified day? ex: to accept a date less than or equal to 100 days(from today).?:(
Thanks for the help in advance.:) (1 Reply)
Discussion started by: abhi_123
1 Replies
8. Shell Programming and Scripting
Can someone please help me with this SHELL script?
I need to create a script that gets a positive number n as an argument. The script must calculate the factorial of its argument. In other words, it must calculate n!=1x2x3x...xn. Note that 0!=1.
Here is a start but I have no clue how to... (3 Replies)
Discussion started by: I-1
3 Replies
9. UNIX for Dummies Questions & Answers
How to find the last argument in a argument line? (4 Replies)
Discussion started by: nehagupta2008
4 Replies
10. Shell Programming and Scripting
Hi,
I am new to UNIX. I am facing some problem here.
#! /usr/bin/ksh
currDate = $1
export currDate;
echo " Date is $currDate"
when I run this script, it says : currDate not found.
Can anybody point out the mistake please.
--mahek (3 Replies)
Discussion started by: mahek_bedi
3 Replies