|
|
Browse by Tags
All Tags » file » text » PowerShell
-
Another translation of an example script from a Hey scripting guy column How Can I Locate a Word in a Text File and Then Echo Back That Word and Any Remaining Text? from VbScript to PowerShell .
I made these 2 different versions within minutes : Get-Content test.txt | out-string |% ...
-
Ars technica did an article about PowerShell : Microsoft PowerShell rolled into Longhorn Server
In this article two PowerShell examples from my blog are used : How to get the uptime of a specific service: $s = gwmi win32_service -filter ''name = 'spooler''' ''{0}'' -f ((get-date) - ([wmi]'').ConvertToDateTime((gwmi ...
-
from the Hey Scripting Guy article :
How Can I Parse a Tab-Delimited File and Then Save That as a Comma-Separated Values File?
gc tab.txt |% {$_.split(''`t'') |? {$_ -match '='} |% {$r = new-object object} {$r | add-Member -memberType noteProperty -name $_.split('=')[0] -Value $_.split('=')[1]}{$r}} | export-csv -NoTypeInformation ...
-
Again I will mimic a Scripting Guy article here in PowerShell, only this time from the Sesame Script series :
Sesame Script: Scripting Text Files
Preamble
As this entry also was written as a training for the International Winter Scripting Games, And just to make you feel even better about entering, this month’s Sesame ...
|
|
|