Re: Perl script: where was I executed from?

wagsworld48 via beginners <[email protected]>
Newsgroups gmane.comp.lang.perl.beginners
Message-ID <aee7ab09-82bd-4e13-b217-79755f68c96d@Spark>
Well, up until this last update is BBEdit, when a script was run while in BBEdit, the Unix log file would automatically come to the fore front. Now it stays hidden.

A gentleman on the BBEdit mail list gave an   osasctipt that one can execute from within the script bring executed. But sometimes I run from terminal session, so don’t want to tell BBEdit to do something is not required. Hence where am I and from that know what to do...

Thoughts??? ;)

WagsWorld
World of Perl
Hebrews 4:15
Ph D:(408)914-1341
Ph M:(408)761-7391
On Nov 21, 2020, 18:09 -0800, Uri Guttman <[email protected]>, wrote:
> On 11/21/20 7:42 PM, wagsworld48 via beginners wrote:
> > It was a good idea, but that gives me zsh which is what in this case
> > BBEdit uses to execute the script. So with your code of $ENV, then I
> > looked at the variables within ENV and picked one that was there for
> > BBEdit and not there in a normal terminal run. Know other ways, but
> > this at least is one way to accomplish the task..
> ok, i am smelling an XY problem here. why do you need to know from where
> the perl was executed? in general processes don't know the path of their
> parent process. one way around this is to pass a special value to the
> perl process (via argument or env) that tells the perl of its origin.
>
> but a bigger question is, why do you need/want to know this? what
> difference will it make to the perl process?
>
> thanx,
>
> uri
>
> --
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
> http://learn.perl.org/
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.