develooper Front page | perl.perl5.porters | Postings from June 2021

Re: RFC - Issue a warning "-np better written as -p"

Thread Previous
From:
Nicholas Clark
Date:
June 16, 2021 09:15
Subject:
Re: RFC - Issue a warning "-np better written as -p"
Message ID:
20210616091536.GA16703@etla.org
On Wed, Jun 16, 2021 at 10:59:29AM +0200, gregor herrmann wrote:
> On Wed, 16 Jun 2021 08:51:19 +0000, Nicholas Clark wrote:
> 
> > ## Backwards Compatibility
> > 
> > This is **hard** to assess.
> > 
> > We can search CPAN for representative use of Perl **code**. With
> > the demise of Google codesearch, there isn't a good way to search
> > for command-line use cases of `perl`. Is it viable to search
> > Debian's source archives? Or the FreeBSD ports tree?
> 
> For Debian the answer is yes:
> https://codesearch.debian.net/
> 
> E.g. https://codesearch.debian.net/search?q=perl.*-np&literal=0
> or https://codesearch.debian.net/search?q=perl.*-w.*-np&literal=0

Merijn has also mentioned $PERL5OPT. I'd not thought of that.

(But on the original PR - please, can we keep discussion in one place. That
was part of the point of trying to have an RFC process - to avoid a spread
of discussion)

In trying out https://codesearch.debian.net/ I spotted that there was at
least one -np on a #! line.

So that's three places we need to consider, and the interaction between
them.


Right, so, I still don't have any good opinion on this, but within 30 minutes
we seem to have flushed out

1) "Command line" actually means all of argv, #! line and $PERL5OPT
2) https://codesearch.debian.net/ is useful for this

That was rather fast, and it's not even lunchtime yet.

Nicholas Clark

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About