LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-13-2007, 03:10 AM   #1
ryanlum
Member
 
Registered: Jul 2007
Posts: 47

Rep: Reputation: 15
Need help on a command.


hey guyz,

i met with this command

sh -x $RUNFILE

what does sh -x do?
 
Old 08-13-2007, 03:13 AM   #2
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Hi. If you run "man sh", you will get more details about the "-x" option. Its related to conditional expressions.
 
Old 08-13-2007, 04:05 AM   #3
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
Quote:
Originally Posted by reddazz View Post
Hi. If you run "man sh", you will get more details about the "-x" option. Its related to conditional expressions.
I would never question a replay from a moderator... but isn't -x supposed to be a debugging option? I used it on Unix in complex shell script projects, as
Code:
#!/bin/sh -x
 
Old 08-13-2007, 04:21 AM   #4
ryanlum
Member
 
Registered: Jul 2007
Posts: 47

Original Poster
Rep: Reputation: 15
thx a bunch ppl..
found out how to use it also..
i tried to man sh before i posted this.. guess the manual wasn't installed.
thx again
 
Old 08-13-2007, 06:51 AM   #5
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Quote:
Originally Posted by colucix View Post
I would never question a replay from a moderator... but isn't -x supposed to be a debugging option? I used it on Unix in complex shell script projects, as
Code:
#!/bin/sh -x
Being a moderator does not mean that I give correct answers , so feel free to question my responses. Anyway, I read the man page before posting and it "-x file" is listed under conditional expressions.
 
Old 08-13-2007, 07:16 AM   #6
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
Quote:
Originally Posted by reddazz View Post
Being a moderator does not mean that I give correct answers , so feel free to question my responses. Anyway, I read the man page before posting and it "-x file" is listed under conditional expressions.
Of course... just kiddin' For completeness to this thread, -x is both a conditional expression if used in a test, and an option to sh or bash command itself: it makes sh to print out a command before it is executed and after any shell expansion.
 
Old 08-13-2007, 09:16 AM   #7
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Ok, thanks for the clarification. I really need to learn a bit more about the SHELL. Its one area that I have neglected for a long time.
 
  


Reply



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
Is there a single command to list all hardware installed (command line)? davee Linux - Hardware 6 02-28-2009 07:19 PM
Require Linux/Perl equivalent command for windows Command alix123 Programming 7 08-19-2005 02:23 AM
Key stroke/command to shut down x and go into the command prompt screen? Fear58 Linux - General 1 07-14-2004 07:14 PM
Command to display whole filestructure hierarchy f/ command line? mjewell Linux - Newbie 10 01-19-2004 10:48 AM
Where is Command line utility for Cups and command tutorial mossy Linux - Software 8 01-16-2004 12:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:46 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration