Can github .gitignore block itself?

modified the contents of the .gitignore file but did not want to submit the .gitnore file, added .gitignore to the .gitignore file but did not work. Is there a solution?

Git
Oct.15,2021

If

does not want to submit, just do not choose not to when git add .
but it should also be achievable. Refer to the following article, Portal

< hr >

if it is helpful, please click to adopt it, thank you ~


first figure out your requirements, why modify the .gitignore file, whether some files have been modified, but do not want to submit them to the repository.
doesn't want to see it exist when git status .

if so, you do not need to modify the .gitignore file.
Edit the .git / info/exclude file under the current project, and then write the file that needs to be ignored. Note that the path to the file is relative to the root of the project.

I hope I can help you!

Menu