Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
TCSH Scripting Help
Name: Phoenix940 Date: September 21, 2008 at 22:53:05 Pacific OS: Linux CPU/Ram: x64/2048Mb Product: ??
Comment:
Hey. My problem is I am trying to write a tcsh script and I need to insure all my arguments are numerical. My solution to the problem was to do: @ test = $argv[$x] >& tempfile #Where x is the given argument number if ( `cat tempfile` == "@: Expression Syntax.") then echo " Non-numerical input given" endif
The problem seems to lie in the fact that the first command (@ test...) produces error and exits the script. If I remove it the test works fine, but I need that for it to work with any given inputs. How can I get TCSH to continue to run even with the error output? Is there a better way to determine if input is numerical? I have the rest of the script written so I really don't want to change to a different shell for the script.
Summary: Hi, I want to write a script which basically monitors the amount of file usage (%) for a specific file system ,say "/mount1" for a amount of %,say 98%...When it reaches this %,it should generate a war...
Summary: I'm stumped with this program I'm working on, can someone help. I'm new to UNIX and wanting to learn. The program I'm working on is to: Write a Korn shell script that will search the UNIX file system ...
Summary: Hi, can anyone help me, I am doing an assignment and I'm having trouble figuring it out. First of all. I am using the Bourne shell and I need to display the user of the shell script their Surname foll...