The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
URL call from SHELL script chengwei Shell Programming and Scripting 35 10-21-2008 05:04 PM
Call shell script from php not run ? raccsdl Shell Programming and Scripting 2 11-19-2007 05:21 AM
how can i call a shell script from pl/sql rajesh.P Shell Programming and Scripting 3 09-16-2007 08:09 PM
how can a call shell script from pl/sql rajesh.P UNIX for Dummies Questions & Answers 0 09-13-2007 11:42 PM
How to call a shell script from awk ? Amruta Pitkar Shell Programming and Scripting 1 04-20-2007 01:35 AM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 02-04-2008
Registered User
 

Join Date: Jan 2008
Location: Bangalore
Posts: 17
shell script to call other files..plz help

Hi all,
I have a number of shell script,perl script.. etc in a directory,which i need to execute in some order.Now i need to create a script to call all these files in that order..so that the new script will execute all the files one by one....plz help this is urgent.


Thanks In advance

Anju

Last edited by anju; 02-04-2008 at 11:07 PM.
Reply With Quote
Forum Sponsor
  #2  
Old 02-04-2008
Yogesh Sawant's Avatar
Part Time Moderator and Full Time Dad
 

Join Date: Sep 2006
Location: Rossem, Tazenda
Posts: 791
Whatever scripts you want to run, write them in a file - the way you would execute them at command line

Write them in the order in which you want to execute them

Your file may look like:
Code:
#!/bin/sh
script_01.sh
script_02.sh
script_03.pl
and then run the file (its basically another shell script) that you have created
Reply With Quote
  #3  
Old 02-05-2008
Registered User
 

Join Date: Aug 2007
Location: Bangalore
Posts: 288
Check out the permissions of the scripts,if they are not executable then change the permissions and run it as Yogesh suggested.
Reply With Quote
  #4  
Old 02-05-2008
Yogesh Sawant's Avatar
Part Time Moderator and Full Time Dad
 

Join Date: Sep 2006
Location: Rossem, Tazenda
Posts: 791
Quote:
Originally Posted by namishtiwari View Post
Check out the permissions of the scripts,if they are not executable then change the permissions and run it as Yogesh suggested.
yes, and the first line in the scripts should begin with #! (something like #!/bin/bash or #!/usr/bin/perl - depending on the shell / language that you are using)
Reply With Quote
Google The UNIX and Linux Forums
Reply

Tags
perl script, shell script

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 04:28 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0