exit if specific apps are running at the time of install
This commit is contained in:
+12
-1
@@ -1,4 +1,15 @@
|
||||
# Path to the MSI installer
|
||||
# Exit early if apps are running
|
||||
$ExitEarly = $false
|
||||
$AppNames = @()
|
||||
If ( IsRunning -Name 'revit' ) { $ExitEarly = $true ; $AppNames.Add('Revit') }
|
||||
If ( IsRunning -Name 'sketchup' ) { $ExitEarly = $true ; $AppNames.Add('SketchUp') }
|
||||
If ( IsRunning -Name 'archicad' ) { $ExitEarly = $true ; $AppNames.Add('ArchiCAD') }
|
||||
If ( IsRunning -Name 'autocad' ) { $ExitEarly = $true ; $AppNames.Add('AutoCAD') }
|
||||
If ( IsRunning -Name 'rhino' ) { $ExitEarly = $true ; $AppNames.Add('Rhino') }
|
||||
If ( IsRunning -Name 'vectorworks' ) { $ExitEarly = $true ; $AppNames.Add('VectorWorks') }
|
||||
If ( $ExitEarly ) { Write-Output "Installation cannot continue because the following apps are running: ${AppNames}." ; Return }
|
||||
|
||||
# Path to the MSI installer
|
||||
$URL = 'https://enscape-installer.chaosgroup.com/installer.enscape.io/Enscape-4.0.2.11.exe'
|
||||
|
||||
# Set path to temp directory
|
||||
|
||||
Reference in New Issue
Block a user