I’m trying to extract a list of file paths from a log file. The problem I’m having is removing the first text in the line so I can have only the path that I need.
I can successfully do:
Get-Content -Path "C:\Temp\files.log" | Select-string -Pattern "Some Text"
And that returns:
Some Text “C:\path1\settings.xml”
Some Text “C:\path2\settings.xml”
Some Text “C:\path3\settings.xml”
How do I remove the “Some Text” from the beginning of each line?