0

I am new to regex, can someone help me figure out how to replace unknown text while reading from a file

I am searching through a file for DEST=XXX

I dont know what XXX could be, I just know it's a 3 letter String

Here what I have so far

   Get-Content -path $filePath -replace 'DEST=\w{3}','DEST=MTG'
Wiktor Stribiżew
  • 607,720
  • 39
  • 448
  • 563
endlessCode
  • 1,255
  • 4
  • 21
  • 36

0 Answers0