What are tracked files and untracked files in the context of Git?

前端 未结 5 1945
逝去的感伤
逝去的感伤 2021-02-02 08:14

I\'m new to Git. I wish to know what are tracked and untracked files? I read \"Pro Git\", but still couldn\'t quite understand.

Can someone explain to

5条回答
  •  礼貌的吻别
    2021-02-02 09:13

    Tracked files are the one handled (version controlled) by Git, that were once added and committed. Untracked files are most of the time files you don't want to be controlled, because for example they are generated by your compiler.

    You add untracked files to the .gitignore file, so that Git don't ask you if you want to track them.

提交回复
热议问题