mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-08-09 13:04:59 +02:00
Improved check for $lastExitCode
This commit is contained in:
@ -22,7 +22,7 @@ try {
|
||||
|
||||
Write-Host "⏳ Searching for pandoc..."
|
||||
$null = (pandoc --version)
|
||||
if ($lastExitCode -ne "0") { throw "Can't execute 'pandoc' - make sure it's installed and available" }
|
||||
if ($lastExitCode -ne 0) { throw "Can't execute 'pandoc' - make sure it's installed and available" }
|
||||
|
||||
Write-Host "⏳ Converting..."
|
||||
gci -r -i $FilePattern | foreach {
|
||||
|
Reference in New Issue
Block a user