Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^2: Cleaning %PATH% with WinBatch

by LanX (Saint)
on May 22, 2022 at 17:01 UTC ( [id://11144090]=note: print w/replies, xml ) Need Help??


in reply to Re: Cleaning %PATH% with WinBatch
in thread Cleaning %PATH% with WinBatch

> Modern berrybrew handles ActiveState as well.

ah good to know °

> And if you can replace text in the path with DISABLED, why can't you replace it with empty, or at least a single semicolon?

I can only replace a fixed leading part not the whole entry because there doesn't seem to be a wildcard mechanism like regex s/c:\\perls\\.*?;//g ... I can only s/c:\\perls\\/DISABLED/g

(Well I could if I iterated over all possible complete entries)

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

update

demo:

c:\tmp>set DEMO=C:\perls\strawberry-perl-5.32.1.1-64bit-portable\perl\ +site\bin; c:\tmp>set DEMO=%DEMO:C:\perls\=DISABLED% c:\tmp>echo %DEMO% DISABLEDstrawberry-perl-5.32.1.1-64bit-portable\perl\site\bin;

update

°) though can't find it mentioned on GitHub...

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (4)
As of 2024-04-18 23:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found