Restructure .gitignore files#4707
Restructure .gitignore files#4707jleveque merged 1 commit intosonic-net:masterfrom jleveque:update_gitignore
Conversation
| @@ -0,0 +1,3 @@ | |||
| * | |||
| !.gitignore | |||
There was a problem hiding this comment.
This line is repeated in many places? Can you remove?
There was a problem hiding this comment.
It's technically not necessary since the .gitignore file is itself added. I added it in all the files because I assume in the future, if someone adds a new directory they will use one of the existing .gitignore files as a template. However, If the file doesn't un-ignore itself, it will not show up in their list of modified files, so it will not get added to their commit and may get overlooked. They would need to make sure to explicitly add the new .gitignore file.
I can simply remove them all if you prefer.
| @@ -0,0 +1,3 @@ | |||
| * | |||
| !.gitignore | |||
| !Makefile | |||
There was a problem hiding this comment.
Why you need unignore? Who ignore it at first place?
There was a problem hiding this comment.
The first line, * ignores everything, then we un-ignore the Makefile here.
There was a problem hiding this comment.
Why ignore everything? That will make things complex.
There was a problem hiding this comment.
Because we only want to commit the Makefile. We don't care about the generated files, and if the generated files change, we will need to update this. This way, we never need to update it unless we need to add any files.
| !debian/changelog | ||
| !debian/compat | ||
| !debian/control | ||
| !debian/rules |
There was a problem hiding this comment.
Merge them into one line rule?
There was a problem hiding this comment.
As with the above, these are inverse ignore rules. We ignore all, then un-ignore the files we want to keep. Otherwise, there would be more lines :)
There was a problem hiding this comment.
debian/* make things complex. Could you just ignore what you want to ignore?
There was a problem hiding this comment.
I disagree. There are more files we want to ignore than the number we want to commit.
| * | ||
| !.gitignore | ||
| !Makefile | ||
| !patch/ |
There was a problem hiding this comment.
The first line, * ignores everything, then we un-ignore the Makefile and patch directory here.
|
Retest mellanox please |
|
Retest vsimage please |
2 similar comments
|
Retest vsimage please |
|
Retest vsimage please |
yxieca
left a comment
There was a problem hiding this comment.
Qi/Joe/Myself had an offline discussion. Qi is ok with moving ahead but he has different opinion on this PR.
Add .gitignore files in each subdirectory of src/, so as to reduce the size of the .gitignore file in the project root, and also make it easier to maintain (i.e., if a directory in src/ is removed, there will not be outdated entries in the root .gitignore file.
Also add missing .gitignore entries and remove outdated entries and duplicates.