Hi Serena I put the .gitignore file inside my repository folder. My 
.gitignore file is currently setup to ONLY ALLOW .sql .yaml files. Also it 
will EXCLUDE the Logs folder inside the repo. I posted what I wrote inside 
the .gitignore file. Also feel free to test your changes. Try blocking all 
.txt files and attempt to add using git, if it doesn't track any changes to 
the text file then you did it correctly. To block all text files simple add 
.txt to the .gitignore file. 

*!*.sql                        # Include all .sql files*
*!*.yaml**                     # Include all .yaml files*
*Logs/**                       # Exclude the Logs folder*


On Wednesday, March 24, 2021 at 8:44:50 PM UTC-4 Serena Li wrote:

> Hello peeps in the git community!
>
> I am slowly learning about the gitignore files for projects and found out 
> that to prevent cluttering in the project .gitignore -> one can create a 
> global .gitignore outside the project folder! And some questions popped 
> up.... 
>
> *Here is my setup:*
> *C:\projects\project-xy*
> *C:\Users\user1*
>
> So, my projects are in the projects folder. Many in the web suggest to put 
> the global .gitignore in the %user% folder.
>
> My stupid question is, do I just stubbornly put my global .gitignore in 
> the "user1" folder or should I put it in my "projects" folder?
>
> And what should I definitely include in my global .gitignore?
> *OS: Windows*
> *Editor: Unity, VS, VS Code, Intellij, Android Studio*
>
> Kind Regards,
> Serena
>

-- 
You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to git-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/git-users/35269739-458c-43ec-b74a-b15bef612dc3n%40googlegroups.com.

Reply via email to