scans.compile.ps1
# Import the Scans module Import-Module ./Scans.psm1 -Function Get-Icon # Set the path to the PS2EXE.ps1 script $ps2exeScriptPath = Join-Path -Path $PSScriptRoot -ChildPath "PS2EXE.ps1" # Set the path to the scans.ps1 script $scansScriptPath = Join-Path -Path $PSScriptRoot -ChildPath "scans.ps1" # Set the output path for the compiled executable $outputPath = Join-Path -Path $PSScriptRoot -ChildPath "scans.exe" # Set the details for the compiled executable $details = @{ Title = "Scans" Description = "Scanning setup utility." CompanyName = "Nick Szitai" ProductName = "Scans" } # Compile the scans.ps1 script using PS2EXE.ps1 & $ps2exeScriptPath -inputFile $scansScriptPath -outputFile $outputPath -noOutput -noConsole -iconFile (Get-Icon) -title $details.Title -description $details.Description -company $details.CompanyName -product $details.ProductName -version 2.0.0.0 -verbose |