• Breaking News

    How to Enable Long Path Support in Git on Windows: A Step-by-Step Guide

    If you're a Windows user working with Git, you might have encountered the annoying Filename too long error. This happens because Windows has a maximum path length limit of 260 characters by default. Fortunately, Git provides an option to bypass this with long path support.

    Here’s a simple step-by-step guide to enable it:



    Step-by-Step: Enable Long Path Support in Git

    Step 1
    : Open Git Bash or Command Prompt
    You can use Git Bash (recommended) or Command Prompt with administrative privileges.

    Step 2: Check the Current Setting
    Run the following command to see if long paths are already enabled:

    git config --system core.longpaths

    If it returns nothing or false, proceed to the next step.

    Step 3: Enable Long Path Support
    To enable long path support, type:

    git config --system core.longpaths true

    This will allow Git to handle files with longer paths than 260 characters.

    Step 4: Confirm the Change
    Run the same command again to verify:

    git config --system core.longpaths

    It should return true.

    Note: If you get a permission error, try running Git Bash as Administrator.

    No comments