Intune App Packaging

Deploy Git for Windows via Intune | Win32 Packaging

Published 17 March 2026 · 6 min read

Git for Windows is essential for developers and IT teams working with version-controlled scripts, infrastructure as code, and source repositories. It uses an Inno Setup EXE installer with a full set of silent switches to control shell integration, file associations, and default editor configuration.

Contents
  1. Download the installer
  2. Wrap with the Content Prep Tool
  3. Add the app in Intune
  4. Install and uninstall commands
  5. Detection rule
  6. Post-install Git configuration

Download the installer

Download the 64-bit installer from the official Git site:

https://git-scm.com/download/win

Click 64-bit Git for Windows Setup. The filename will be Git-2.x.x-64-bit.exe. Always download the latest stable release.

Wrap with the Content Prep Tool

IntuneWinAppUtil.exe -c "C:\AppSource\Git" -s "Git-2.44.0-64-bit.exe" -o "C:\IntunePackages"

Add the app in Intune

Intune Admin Centre → Apps → Windows → + Add → Windows app (Win32)
  1. Upload the .intunewin file
  2. Name: Git for Windows
  3. Publisher: The Git Development Community

Install and uninstall commands

⚙️
Program settings
Inno Setup switches for Git
Install commandCOMPONENTS controls shell integration - adjust to your needs
Git-2.44.0-64-bit.exe /VERYSILENT /NORESTART /NOCANCEL /SP- /CLOSEAPPLICATIONS /COMPONENTS="icons,ext\reg\shellhere,assoc,assoc_sh"
Uninstall command
C:\Program Files\Git\unins000.exe /VERYSILENT /NORESTART
Install behaviour
System
Device restart behaviour
No specific action
💡
COMPONENTS switch
The COMPONENTS value controls what gets installed: icons = desktop shortcut, ext\reg\shellhere = right-click "Open Git Bash here", assoc = .git file associations, assoc_sh = .sh file associations. Remove any you do not want.

Detection rule

🔍
File detection rule
[]
Rule type
File
Path
C:\Program Files\Git\cmd
File or folder name
git.exe
Detection method
File or folder exists
💡
Test your detection rule first
Before deploying to users, install the app manually on a test device and verify the detection rule matches. Check the file path or registry key exists before assigning to a group.

Post-install Git configuration

# Set system-wide Git defaults (applies to all users on the device)
# Deploy as a separate Intune PowerShell device script after Git installs

$git = "C:\Program Files\Git\cmd\git.exe"

# Handle line endings (recommended for Windows)
& $git config --system core.autocrlf true

# Use Windows Credential Manager
& $git config --system credential.helper wincred

# Set default branch name
& $git config --system init.defaultBranch main

Frequently Asked Questions

Q: How do I deploy Git for Windows silently via Intune?

Use: Git--64-bit.exe /VERYSILENT /NORESTART /NOCANCEL /SP- /CLOSEAPPLICATIONS /RESTARTAPPLICATIONS /COMPONENTS="icons,ext\reg\shellhere,assoc,assoc_sh". Download from git-scm.com/download/win.

Q: Does Git for Windows have an MSI installer?

No. Git for Windows uses an Inno Setup EXE installer. Use the /VERYSILENT switch for silent deployment. The /COMPONENTS switch controls which optional components are installed such as shell integration and file associations.

Q: How do I detect Git for Windows in Intune?

Use a file detection rule: check for git.exe in C:\Program Files\Git\cmd. This is consistent across all Git versions.

Q: How do I configure Git globally after deploying via Intune?

Deploy a PowerShell script via Intune after the Git install that runs git config --system to set global defaults like core.autocrlf and credential.helper. System-level config applies to all users on the device.

More App Packaging Guides
Deploy PowerShell 7 via Intune Deploy Wireshark via Intune
Installer typeEXE (Inno Setup)
Silent installYes - /VERYSILENT /NORESTART
Shell integrationVia /COMPONENTS switch
Install pathC:\Program Files\Git
Reboot requiredNo
// need intune set up properly?
Fixed-price Intune setup for UK businesses

I set up Intune for UK small businesses at a fixed price - app deployment, compliance policies, Conditional Access, and full documentation handed over at the end.

View Packages
#intune #app-packaging #win32