Commit 744e67fe authored by Dustin L. Howett's avatar Dustin L. Howett

[Format-Clang] improve pipeline & file-not-found support

parent ccdf0729
[CmdletBinding()]
Param (
[Parameter(Mandatory=$true,ValueFromPipeline=$true)]
[string[]]$Files
[string[]]$Path
)
& clang-format -i (Get-Item $Files | Select -Expand FullName)
Process {
ForEach($_ in $Path) {
Try {
$n = Get-Item $_ -ErrorAction Stop | Select -Expand FullName
& clang-format.exe -i $n
} Catch {
Write-Error $_
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment