Rotten Code

it can always work better - but at least it should work

  Home  |   Contact  |   Syndication    |   Login
  18 Posts | 0 Stories | 12 Comments | 2 Trackbacks

News



Archives

Recommended Podcasts

August 2008 Entries

So you want to determine if a folder or file exists with PowerShell? You can invoke the same scripting object you might remember from VB.... #set a var for the folder you are looking for $folderPath = 'C:\Temp\' #instantiate the FileSystemObject $objFSO = New-Object -ComObject Scripting.FileSystemObject #check to see if it is missing if($objFSO.FileExists($fold... -eq $FALSE)) { echo "The folder does not exist." exit } else { echo "The folder exists." exit }...
  • Share This Post:
  • Share on Twitter
  • Share on Facebook
  • Share on Technorati

I gotta admit, I really like PowerShell. No, that's not accurate. I love PowerShell. I love PowerShell like babyback ribs love sauce. My relationships with PowerShell has bloomed from piqued interest to full blown infatuation. PowerShell fits the bill of what I look for with tools - not overly engineered, actually useful, lightweight and extensible. But since I have taken such a liking to PowerShell, that makes me wonder...isn't PowerShell supposed to be designed for admins who aren't programmers?...
  • Share This Post:
  • Share on Twitter
  • Share on Facebook
  • Share on Technorati