Skip to content

Repository cannot be cloned on Windows due to reserved filename #173

@ms0017

Description

@ms0017

Problem Description
Cloning this repository on Windows fails due to the file living/con.md using a Windows-reserved filename. The clone operation partially succeeds but checkout fails, leaving the repository in an unusable state.

Error Output

error: invalid path 'living/con.md'
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed.

Root Cause/ Suggested Fix
CON is a reserved device name in Windows and cannot be used as a filename, regardless of extension. This restriction dates back to MS-DOS and applies to all modern Windows versions.
According to Microsoft's official documentation on naming files:

Do not use the following reserved names for the name of a file: CON, PRN, AUX, NUL, COM0-COM9, LPT0-LPT9. Also avoid these names followed immediately by an extension; for example, NUL.txt is not recommended.

Current Workaround

git clone --no-checkout https://github.com/commoncrawl/web-languages/
cd .\web-languages\
git config core.protectNTFS false
git checkout

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions