LinuxQuestions.org
Visit Jeremy's Blog.
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 02-09-2015, 07:01 PM   #1
oraenthu@live.com
LQ Newbie
 
Registered: Sep 2012
Posts: 26

Rep: Reputation: Disabled
get the filename where the variable is set


Hello,
Host machine: Windows seven 64 bit
Guest machine on Virtual box: Oracle linux 6.5(64 bit)

If there are multiple files sourced, each containing many variables,and each in a location not known to the person using a user,
is there a way to know the file name where the variable is set?

Many thanks
 
Old 02-09-2015, 07:37 PM   #2
grail
LQ Guru
 
Registered: Sep 2009
Location: Perth
Distribution: Manjaro
Posts: 9,255

Rep: Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686Reputation: 2686
You could try man bash and checkout the builtin variables, however, this may not help you all that much if more than one file sets the same variable you may not know which one set it last.

What would be the reason to find said files?
How are these files being sourced?
Can you not read in the file(s) doing the sourcing?
 
  


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
bash: variable is a filename not a list ezekieldas Programming 4 02-15-2014 02:07 PM
Make a variable = filename without the extension greengrocer Linux - Newbie 8 04-24-2011 11:16 AM
replace filename with variable Siljrath Programming 2 11-12-2009 01:40 AM
Read filename as a variable kicap Programming 3 08-12-2009 05:27 PM
Using a variable containing a filename in grep TrumpetMan258 Programming 2 03-01-2008 02:27 PM


All times are GMT -5. The time now is 02:08 AM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration