LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 09-26-2002, 10:47 PM   #1
chandhru
LQ Newbie
 
Registered: Sep 2002
Posts: 2

Rep: Reputation: 0
how to run a shell script in Linux


Hi,

I have downloaded ipkg-build.sh script in my Linux . i dont khow
how to run that script and make it working.

also i have a basic doubt , what is script . why do we need scripts
to run certain programs

Thanks
Chandhru
 
Old 09-26-2002, 11:16 PM   #2
jimjim
LQ Newbie
 
Registered: Sep 2002
Location: australia
Posts: 6

Rep: Reputation: 0
make sure the script has execute permision
chmod u+x <scriptname>
then type ./<scriptname> in the directory the script is in
 
Old 09-27-2002, 01:19 PM   #3
adam_boz
Member
 
Registered: Jul 2002
Location: Santa Cruz, CA
Distribution: lfs
Posts: 538

Rep: Reputation: 30
In my experience, i've used "sh ./<filename.sh>" A shell script is basically a text file that has a bunch of commands in it. like this srcipt:
#!/bin/sh
cd /usr/src
ls -l

will change to /usr/src/ and then do a ls -l.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
run shell script on cron varunbihani Linux - Newbie 5 07-08-2005 01:50 AM
How to run SHELL script pito Linux - Newbie 4 12-17-2004 03:05 AM
Shell script to run pl/sql script. colly Linux - General 1 09-09-2004 06:49 AM
how do i run shell script? krt47 Linux - Newbie 4 08-02-2004 09:29 AM
how to run a shell script oasisbhrnw99 Linux - Newbie 1 05-05-2004 01:21 PM


All times are GMT -5. The time now is 07:52 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration