Installing_Git
Installing Git
Get Git installed on any operating system.
π₯οΈ Windows
Using Winget (Recommended)
winget install --id Git.Git -e --source winget
Installs Git using Windows Package Manager. The
-eflag ensures exact match.
Using Chocolatey
choco install git
Installs Git using Chocolatey package manager.
Manual Download
Download from: https://git-scm.com/download/win
π macOS
Using Homebrew (Recommended)
brew install git
Installs Git using Homebrew package manager.
Using Xcode Command Line Tools
xcode-select --install
Installs Git along with other developer tools from Apple.
Manual Download
Download from: https://git-scm.com/download/mac
π§ Linux
Ubuntu / Debian
sudo apt update
Updates package list.
sudo apt install git
Installs Git from apt repository.
Fedora
sudo dnf install git
Installs Git using DNF package manager.
Arch Linux
sudo pacman -S git
Installs Git using Pacman package manager.
CentOS / RHEL
sudo yum install git
Installs Git using YUM package manager.
β Verify Installation
git --version
Displays the installed Git version. Example output:
git version 2.43.0
π Update Git
Windows (Winget)
winget upgrade --id Git.Git
Updates Git to latest version using Winget.
macOS (Homebrew)
brew upgrade git
Updates Git to latest version using Homebrew.
Linux (Ubuntu/Debian)
sudo apt update && sudo apt upgrade git
Updates Git to latest version from apt repository.
π Installation Flow
graph TD
A[Choose OS] --> B{Windows?}
B -->|Yes| C[winget install Git.Git]
B -->|No| D{macOS?}
D -->|Yes| E[brew install git]
D -->|No| F{Linux?}
F -->|Yes| G[apt/dnf/pacman install git]
C --> H[git --version]
E --> H
G --> H
H --> I[β
Git Installed]
π Related
#git #installation #setup