LinuxQuestions.org
Help answer threads with 0 replies.
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 08-25-2010, 01:32 AM   #1
sandlinux
LQ Newbie
 
Registered: Aug 2009
Posts: 5

Rep: Reputation: 0
looking for alternative to $0 in bourne shell


I am looking for an alternative to using $0 in bourne shell. I am in the process of migrating all my production shell scripts to a new tool that will automate execution and release of "jobs" in my production system.

And this tool does not like the usage of $0. Which means echo $0 or "basename $0" returns null.

Any ideas ? please enlighten me.


Thank you all so much ,

Sandeep
 
Old 08-25-2010, 01:41 AM   #2
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Hi -

It doesn't sound like a very good tool

What about this:

a) you exported "$0" to SOME_VARIABLE_NAME_THATS_NOT_ZERO

b) call your script (which now has "SOME_VARIABLE_NAME_THATS_NOT_ZERO" defined in its environment)?

Just a thought

Last edited by paulsm4; 08-25-2010 at 01:42 AM.
 
Old 08-26-2010, 10:47 AM   #3
sandlinux
LQ Newbie
 
Registered: Aug 2009
Posts: 5

Original Poster
Rep: Reputation: 0
Thank you for your response. I thought so on the same line as well. Hoping the tool vendors will respond to my query.
 
  


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
Programming in Bourne Shell sourkeys Programming 6 03-14-2010 12:12 PM
xargs bourne shell bazzano Programming 5 04-16-2009 07:11 AM
'sh' shell - Actually calls legacy Bourne shell, or uses system default? Dtsazza Linux - Software 1 10-28-2005 09:20 AM
Bash Shell vs Bourne infamous41md Linux - Newbie 14 04-11-2003 10:16 PM
Bourne Again SHell help MagInnovision Linux - Newbie 2 02-04-2003 03:43 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:38 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