Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^3: Simple CLI calculator based on Perl's eval()

by kcott (Archbishop)
on Jun 03, 2021 at 00:00 UTC ( [id://11133447]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Simple CLI calculator based on Perl's eval()
in thread Simple CLI calculator based on Perl's eval()

G'day Rolf,

I have a whole series of functions and aliases of the form perlX, where X is a lowercase letter. Here's a couple of examples.

This one I use almost every day. It's been in my toolbox since the mid '90s. It probably started as a simple contraction of perl -e; then -e became -E; strict and warnings were added; and so on. The -MCarp::Always is a fairly recent addition.

$ alias perle alias perle='perl -Mstrict -Mwarnings -Mautodie=:all -MCarp::Always -E +'

This one's for Unicode work.

$ alias perlu alias perlu='perl -Mstrict -Mwarnings -Mautodie=:all -Mutf8 -C -E'

These are all for my own personal use. As I've added more over the years, some obvious letters were already taken so alternative (less obvious) ones were used. Only having to remember a single letter is easy for me and not confusing at all; in fact, it's mostly muscle memory. Remembering the historical reasoning behind the choice of a letter is far less important and, in some cases, gets forgotten.

Addendum: It looks like you've hard-coded the "less confusing" link to https://perlmonks.org/?node_id=11133350. Following that link puts me in a logged-out (Anonymous Monk) state. Please fix by changing that to [id://11133350|less confusing].

— Ken

Replies are listed 'Best First'.
Re^4: Simple CLI calculator based on Perl's eval()
by LanX (Saint) on Jun 03, 2021 at 12:58 UTC
    > Please fix by changing that to [id://11133350|less confusing]

    Ah thanks for pointing this out, it's a bug in my wikisyntax.

    I'll add it to the to-do list :)

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    Wikisyntax for the Monastery

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11133447]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others exploiting the Monastery: (6)
As of 2024-04-25 08:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found