Unkown filename appears on hierarachical while commiting

I do not understand one file which is not on git repository & not on local repository (not even local & physical folder) but while i am going to commiting or push it seems in files hierarachical? By unchecking this file i am able push & pull code properly but i am curious to find what is the exact issue.

enter image description here

  • How to include ReactiveCocoa 3.0 in Xcode 7 project
  • Xcode no longer showing me deprecated warnings
  • Configuring Git in XCode4 shows “Host is unreachable”
  • Source tree crashes with many uncommitted changes on Xcode (possibly other IDEs)
  • Which Xcode project files can I 'exclude' from my git repo?
  • CocoaPods “editable” mode?
  • Fastlane Appfile in GIT? How to retrieve current apple_id?
  • Is there a way to make git automatically retry commands if index.lock exists?
  • 3 Solutions collect form web for “Unkown filename appears on hierarachical while commiting”

    .DS_Store is a hidden file, which is created by MacOS to store the information about the containing folder. You should add this file to your .gitignore, so the git will never display it in your untracked/modified list.

    According to wikipedia:

    In the Apple macOS operating system, .DS_Store is a file that stores
    custom attributes of its containing folder, such as the position of
    icons or the choice of a background image. The name is an
    abbreviation of Desktop Services Store, reflecting its purpose. It
    is created and maintained by the Finder application in every folder

    It seems you have changed filename EditOrNewAddressVuewController.m to EditOrNewAddressVuewController~.mthat is saved this info in .DS_Store & you pushed code to remote thereafter this because that .DS_Store info there is untracked file appears on you Git working tree hierarchy,

    If you don’t like this untracked file,delete .DS_Store add .gitignore file. Helpful link1, link2,link3

    Even if, there is one silly way for avoiding to watch this,Clone project in another folder 😉

    .DS_Store is MacOS system file that will appear in each directory for default HFS+ filesystem. Your Finder most likely is not dispaying hidden files (with dot prefix). You can setup .gitignore not to include .DS_Store, details here

    Git Baby is a git and github fan, let's start git clone.