Reputation: 127
I have a project setup, where I have one git repo with two folders in it. Each folder is a separate project in PyCharm. Both projects are connected to that repo. When I update the code of one project, the other project notices that and adds the files from the other project to its own commit options:
The yellow/orange highlighted files are non-project files, and I only want the project to automatically add files to commit that are included in the project. I can of course just choose the files I want to commit, but sometimes I miss a file, which is problematic, and it would be nice if I didn't have to select files each time.
So, is there a way to exclude non-project files from commit options by default?
Upvotes: 1
Views: 1255
Reputation: 197
You could create a .gitignore
file in the repo where git is working and add the locations of the non-project files or folders you don't want to be included in the commit. More info .gitignore and here stackoverflow
Upvotes: 2