What does .gitignore do? #22729
-
I know, this is a newbie question… and this may be the wrong category to put this in. But I don’t understand this. Can anyone help? Thanks in advance! ❤️ |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Hello @Jme7,
As another, more simple example, on one of my projects I keep a folder called “OFFLINE_ASSETS” where I have binaries, personal notes, and some pre-production stuff that I don’t want to clutter the repo with. The contents look like this:
When committing changes, both the .gitignore file and OFFLINE_ASSETS folder are ignored. |
Beta Was this translation helpful? Give feedback.
-
@SethClydesdale Ok, now I understand that. Thanks! |
Beta Was this translation helpful? Give feedback.
Hello @Jme7,
.gitignore
is used for excluding certain files or directories from your commits that you don’t want committed to the main repository, such as temporary files created by IDEs for example. More info here.As another, more simple example, on one of my projects I keep a folder called “OFFLINE_ASSETS” where I have binaries, personal notes, and some pre-production stuff that I don’t want to clutter the repo with. The contents look like this:
When committing changes, both the .gitignore file and OFFLINE_ASSETS folder are ignored.