Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Question on Strawberry's Portable .bat file

by KevinZwack (Chaplain)
on Aug 03, 2012 at 17:28 UTC ( #985295=perlquestion: print w/replies, xml ) Need Help??

KevinZwack has asked for the wisdom of the Perl Monks concerning the following question:

Not a Perl question per se, but I am trying to deploy Strawberry Perl's PortableZIP, and for the life of me I cannot figure out what the If statement in line 4 below does: (from portableshell.bat)

@echo off set drive=%~dp0 set drivep=%drive% If $#\#$==$#%drive:~-1%#$ set drivep=%drive:~0,-1% set PATH=%drivep%\perl\site\bin;%drivep%\perl\bin;%drivep%\c\bin;%PATH +% rem env variables set TERM=dumb set PERL_JSON_BACKEND=JSON::XS set PERL_YAML_BACKEND=YAML rem avoid collisions with other perl stuff on your system set PERL5LIB= set PERL5OPT= set PERL_MM_OPT= set PERL_MB_OPT= echo ---------------------------------------------- echo Welcome to Strawberry Perl Portable Edition! echo * URL - echo * see README.portable.TXT for more info echo ---------------------------------------------- perl -e "printf("""Perl executable: %%s\nPerl version : %%vd\n""", $ +^X, $^V)" 2>nul if ERRORLEVEL==1 echo.&echo FATAL ERROR: 'perl' does not work; check i +f your strawberry pack is complete! echo. cmd /K

The rest of the script all makes sense to me. This is in regards to Rule of Life #23, "Never ask your users to use something which you yourself do not understand, because you know they will ask about it."

Kevin Zwack

Replies are listed 'Best First'.
A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://985295]
Front-paged by Arunbear
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (11)
As of 2022-01-18 14:10 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (53 votes). Check out past polls.