Skip to content

Commit

Permalink
add parameter "-NoProfile" to powershell command
Browse files Browse the repository at this point in the history
Adds the command line parameter `-NoProfile` to the powershell command to avoid error messages on some systems and faster execution.
  • Loading branch information
hhaensel committed Aug 27, 2023
1 parent f2c0b4c commit 290e25d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/_powershell.jl
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function _powershell(img::AbstractMatrix{<:Colorant})
getfile = `\$file = get-item\(\"$(path_png)\"\)\;`
getimg = `\$img = \[System.Drawing.Image\]::Fromfile\(\$file\)\;`
copyimg = `\[System.Windows.Forms.Clipboard\]::SetImage\(\$img\)\;`
cmd = `powershell $addtype $adddrawing $getfile $getimg $copyimg`
cmd = `powershell -NoProfile $addtype $adddrawing $getfile $getimg $copyimg`

Check warning on line 47 in src/_powershell.jl

View check run for this annotation

Codecov / codecov/patch

src/_powershell.jl#L47

Added line #L47 was not covered by tests
run(cmd)
end
end

0 comments on commit 290e25d

Please sign in to comment.