Two methods to obtain the git repository: git init and git clone. The newly added files (including folders) after these two commands are not included in the git repository management. At this time, the status of git st is: Untracked files, which is required Only manual git add can be included in the git warehouse, otherwise git will be out of control. For such files newly added to the working directory, there is a special command for reverse operation: git clean -fd. You can use man git clean to view command instructions.
Because the newly created folders and files are ‘Untracked files’, you can use
git clean -fd
if you want to discard them.Two methods to obtain the git repository:
git init and git clone. The newly added files (including folders) after these two commands are not included in the git repository management. At this time, the status of git st is: Untracked files, which is required Only manual git add can be included in the git warehouse, otherwise git will be out of control.
For such files newly added to the working directory, there is a special command for reverse operation: git clean -fd. You can use man git clean to view command instructions.