PowerShell module to create an organised directory structure for building Microsoft Endpoint Manager Win32 Apps.
Creating win32 apps in Microsoft Endpoint Manager can become quite complex if the app you are installing has multiple install commands, or a custom detection/requirements script. And quite often you will have to document the the process and decisions made for use at a later date when updating the package. This module will enable you to create the directory structure to help packaging the app, and store information in the readme.md
file which can then be stored in source control.
Module version 0.1.4 contains IntuneWinAppUtil.exe version 6.2206.38.0
PowerShell Gallery download/install
Install-Module -Name "MEM-Win32App-Builder"
To update the module
Update-Module -Name "MEM-Win32App-Builder"
To create a an app packaging directory called Test-App-1.0
in the C:\Apps
directory, run the following:
New-MemWin32AppBuild -Name "Test-App-1.0" -Path "C:\App"
You can then populate the directories with the following:
- detection : This folder will contain your
detection.ps1
file if you determine the app requires one. - icon : The icon for the app. Delete the default
intune.png
file. - outputIntuneWin : This is where the your app's
intunewin
file will be output to. - requirements : This folder will contain your
requirements.ps1
file if you determine the app requires one. - source : This contains the
exe/msi
and anycmd
scripts required to install
The following files in the root of the new app package directory are as follows:
- build.cmd : Once all app files are in-place and you are ready to create the
intunewin
file, edit theexe
name inbuild.cmd
and run it. - IntuneWinAppUtil.exe : This is the Microsoft binary used to build the
intunewin
file. - readme.md : Can be used for documentation.
Once you all files in place you can run build.cmd
. This will delete the IntuneWinAppUtil.exe
as you would not want multiple copies of this in source control. But if you want to download it again you can use the following command.
Invoke-DownloadWin32AppUtil -Path "C:\AppPackages"
Example install, detection and requirements scripts for Win32 apps TBC.