Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: Practical joke

by Falkkin (Chaplain)
on Jan 25, 2001 at 06:20 UTC ( #54185=note: print w/ replies, xml ) Need Help??


in reply to Practical joke

Amusing.... although, assuming your coworkers are using bash, this could be made more realistic by doing something like the following:

my $prompt = $ENV{PS1}; $prompt =~ s|\\u|$ENV{USER}|g; $prompt =~ s|\\h|$ENV{HOSTNAME}|g;
... and so on.


Comment on Re: Practical joke
Download Code
Re: Re: Practical joke
by Fastolfe (Vicar) on Jan 25, 2001 at 10:47 UTC
    I had to go a bit further:
    my $prompt = $ENV{PS1}; $ENV{HOSTNAME} =~ s/\..*//; $prompt =~ s!\\u!$ENV{USER}!g; $prompt =~ s!\\h!$ENV{HOSTNAME}!g; $prompt =~ s!\\w!$ENV{PWD} eq $ENV{HOME} ? '~' : $ENV{PWD}!eg; $prompt =~ s!\\\$!$> ? '$' : '#'!eg;

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (9)
As of 2014-07-28 10:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (195 votes), past polls