![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Rules & FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Getting Command line on HP-UX | rucha_mahajan | HP-UX | 2 | 05-12-2008 01:06 AM |
| how to? launch command with string of command line options | TinCanFury | Shell Programming and Scripting | 5 | 04-28-2008 03:06 PM |
| Add line command | felixwhoals | UNIX for Dummies Questions & Answers | 3 | 12-16-2007 08:12 PM |
| find and replace command in one line using one command | vasikaran | UNIX for Dummies Questions & Answers | 3 | 09-04-2007 12:13 AM |
| how to tell which OS via command line | hankooknara | UNIX for Dummies Questions & Answers | 4 | 05-15-2007 08:39 PM |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
Use of IF command in the command line.
What is the command line syntax for the if exist command in Unix like in DOS/WIN which test for the existance of a file?
Is the syntax the same in a script? Thanx |
| Forum Sponsor | ||
|
|
|
|||
|
yeah..., that is the continuation marker.
You can type: if [[ -f filename]] then [ENTER] echo "File exists" [ENTER] else [ENTER] echo "File does NOT exist" [ENTER] endif [ENTER] ...and it should respond accordingly |
|||
| Google UNIX.COM |