Skip to content

Instantly share code, notes, and snippets.

@hanson-andrew
Created February 14, 2013 02:01
Show Gist options
  • Save hanson-andrew/4950084 to your computer and use it in GitHub Desktop.
Save hanson-andrew/4950084 to your computer and use it in GitHub Desktop.

Revisions

  1. hanson-andrew created this gist Feb 14, 2013.
    8 changes: 8 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,8 @@
    Get-ChildItem * -Recurse -Include *.php,*.css,*.js | ForEach-Object {
    $wholeFile = [IO.File]::ReadAllText( $_.FullName )
    if ($wholeFile -match "`r[^`n]")
    {
    $content = Get-Content $_.FullName
    $content | Set-Content $_.FullName
    }
    }