Created
July 8, 2025 11:13
-
-
Save ClosedPort22/63d6befdc7549645af48292ba2c654ed to your computer and use it in GitHub Desktop.
.gitignore in whitelist mode
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # This file demonstrates how to effectively use Git in whitelist mode. All | |
| # files and directories are ignored unless explicitly allowed by lines starting | |
| # with a !. | |
| # As an example, below is a .gitignore file that can be used to track modified | |
| # config files in the user's home directory. | |
| # Ignore all files and directories at the root level | |
| # Note: * doesn't descend into subdirectories | |
| /* | |
| # Git | |
| !.gitignore | |
| !.gitconfig | |
| # Bash related | |
| !.bash_profile | |
| !.bashrc | |
| !.inputrc | |
| # .desktop entries | |
| # Allow '~/local' | |
| !.local | |
| # Ignore everything in '~/local/' ... | |
| .local/* | |
| # ... except 'share' | |
| !.local/share | |
| # Ignore everything in '~/local/share/' ... | |
| .local/share/* | |
| # ... except 'applications' | |
| !.local/share/applications | |
| # You may put a '.gitignore' in '~/.local/share/applications/' to ignore | |
| # 'mimeinfo.cache' or do it in here directly | |
| !.config | |
| .config/* | |
| # pip | |
| !.config/pip | |
| .config/pip/* | |
| !.config/pip/pip.conf | |
| # personal fontconfig config | |
| !.config/fontconfig | |
| .config/fontconfig/* | |
| !.config/fontconfig/conf.d |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment