Synopsis: Based on the bestselling novel by master storyteller Nicholas Sparks, THE LONGEST RIDE centers on the star-crossed love affair between Luke, a former champion bull rider looking to make a comeback, and Sophia, a college student who is about to embark upon her dream job in New York City's art world.
More on that here. Note that if we want to delete all files older than X we would use-lt. ie, the timestamp of the file is older than 15 minutes ago. If we want to delete files newer than X we would use-gt. ie, the timestamp of the file is newer than 15 minutes ago.X, in our case, is the time now minus 15 minutes.owershell: delete files older than X. It really is that easy. Get-ChildItem $env:temp /myfiles | where { $_ .Lastwritetime-lt (date).addminutes(- 15)} | remove-item. E verybody has needed the 'delete files older than X' script.
However, PowerShell doesn't have a native cmdlet for replacing strings of text in files, so I wrote the Replace-FileString.ps1 script to fill this void. After I show you how to take advantage of PowerShell's native capabilities, I'll show you how to use Replace-FileString.ps1. When working with text files, it's often useful to be able to replace strings in a file using regular expressions, then write the results back to the original file. Because there isn't a PowerShell cmdlet that provides this functionality, I wrote