[Melbourne-pm] $0 manipulation
mathew.blair.robertson at gmail.com
Thu Aug 30 23:23:50 PDT 2012
> So how do I update $0 to show script status, but also to have pod2usage,
>> FindBin, etc do the right thing?
>> I dont expect an easy answer to this... other than:
>> a) wont fix
>> b) use some variation of another variable ** to fix either the CPAN
>> or script status.
>> ** I vote $^0... I dont think it is being used, and it follows both the
>> $0 =
>> name and $^ = internal-var convention.
> > Thoughts?
> There is a Sys::ProcTitle module on cpan that avoids $0, might suit
I am familiar with that module, see also Sys::Prtcl, which implements the
same function call (except that is does it via syscall.ph). ACAIK, this
only sets the 16byte system proc entry.
Also worth mentioning, that the perldoc for 'perlvar $0' says that as of
V5.14, prctl() is already being called.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Melbourne-pm