search

Home  >  Q&A  >  body text

The file directory structure of the github web page is inconsistent with the local one

I modified the file name locally before, that is, the English name simply changed the capitalization of the first letter. But now there are differences between the local files and the remote repository. The directory structure displayed on the web page is as shown below:

But the directory structure after my local clone is as follows

Actually, what I need is my local directory structure. Is there any way to solve the problem that the local directory structure is inconsistent with the remote directory structure.

高洛峰高洛峰2793 days ago748

reply all(4)I'll reply

  • 世界只因有你

    世界只因有你2017-05-02 09:39:24

    • Ah? What's the situation? I've solved it myself. fork

    • Data portal


    • [Supplement] I cloned it and found that there was indeed a problem.

    • [Supplement] Unix-like operating systems use a case-sensitive file system, while the file systems of Windows and Mac OS X (default installation) are case-insensitive.


    • git clone

      git clone https://github.com/zhiqiang21/blog

    • Make the repository case-insensitive

      git config core.ignorecase true

    • Modification

      Life

      git mv Life non-exist-filename
      git mv non-exist-filename Life
      git add *
      git commit -m"修改大小写"

    • Modification

      Technology

      git mv Technology non-exist-filename
      git mv non-exist-filename Technology
      git add *
      git commit -m"修改大小写"


    • You'd better create a

      and upload the system files on it. The content is: .gitignore,防止把mac

      # OS generated files #
      ######################
      .DS_Store
      .DS_Store?
      ._*
      .Spotlight-V100
      .Trashes
      ehthumbs.db
      Thumbs.db 

    • reply
      0
  • 世界只因有你

    世界只因有你2017-05-02 09:39:24

    Clone, change the file name to another name, and then change it back to the correct case (directly changing the case will be ignored by some systems), delete the redundant files

    reply
    0
  • 黄舟

    黄舟2017-05-02 09:39:24

    *nix systems (including MacOS) strictly distinguish between upper and lower case of file names, but this is also related to the file system. Under *nix, file systems related to Windows do not distinguish between upper and lower case of file names, because Windows itself does not distinguish between upper and lower case. .
    Post the address and I will clone it and see what happens under Windows.

    reply
    0
  • 高洛峰

    高洛峰2017-05-02 09:39:24

    Thank you for the invitation, that’ll be it. . gitignoreFilter files

    reply
    0
  • Cancelreply