# Git Installation

## Installation Guide

*   **Windows:**

    * Visit [git-scm.com](https://git-scm.com/), click "Download for Windows," and run the installer.
    * During installation, choose default settings unless specified otherwise.

    **Mac OSX:**

    * Open Terminal and use Homebrew: `$brew install git`.
    * If Homebrew is not installed, follow instructions at [brew.sh](https://brew.sh/).

    **Linux:**

    * Open Terminal and use your package manager. For Debian/Ubuntu: `$sudo apt install git`.
    * For Fedora: `$sudo dnf install git`.

    **Verify Installation:**

    * Open Terminal or Command Prompt.
    * Type `$git --version` to check if Git is correctly installed. You should see an output similar to `git version 2.x.x`.

    **Configure Git User Details:**

    * Set your username: `$git config --global user.name "`<mark style="color:orange;">`Your Name`</mark>`"`
    * Set your email: `$git config --global user.email "youremail@example.com"`
    * Verify your settings: `$git config --list`

    **Sample Example:**

    * Create a new directory: `$mkdir`` `<mark style="color:orange;">`MyFirstRepo`</mark>` ``&& cd M`<mark style="color:orange;">`yFirstRepo`</mark>
    * Initialize Git: `$git init`
    * Create a sample file: `$echo "Hello, Git!" >`` `<mark style="color:orange;">`README.md`</mark>
    * Stage the file: `$git add README.md`
    * Commit the file: `$git commit -m "Initial commit"`
    * **Student Activity:**
      * Install Git on your system following the steps above.
      * Verify your installation and configure your username and email.
      * Initialize a new Git repository in a folder named `GitPractice`.
      * Create a file named `practice.txt`, add some text, stage, and commit the file.
      * Run `$git log` to view your commit history.

    By completing these steps, you'll have a basic understanding of installing and configuring Git, creating a repository, and making your first commit.

##
