This document defines the standards and guidelines for contributing .gitignore templates to the GitHub gitignore repository. It covers template quality criteria, contribution requirements, placement rules, versioning strategies, and documentation expectations. The repository serves as the source for the .gitignore template choosers available in the GitHub.com interface when creating new repositories README.md3-5
For information about the repository's organizational structure, see Repository Structure and Organization (1.1) For practical guidance on using existing templates, see Using Gitignore Templates (1.2)
Sources: README.md1-67
A template qualifies for inclusion in this repository when it satisfies specific quality and scope requirements. The repository curates the most common and helpful templates rather than attempting comprehensive coverage of every tool README.md60-63
| Criterion | Description | Example |
|---|---|---|
| Specific Scope | Must target a specific programming language, framework, tool, or environment README.md42-44 | Python.gitignore, Node.gitignore, VisualStudio.gitignore |
| Curated Rule Set | Must contain a small, meaningful set of rules README.md24-26 | Excludes templates that are mostly lists of specific version files |
| Universal Applicability | Rules should apply to everyone using the technology CONTRIBUTING.md13-15 | Not specific to individual teams or organizations |
| Active Maintenance | Technology must be in active use and the template must be "evergreen" at root README.md74-76 | Not deprecated or obsolete tools |
Templates are not accepted when:
.DS_Store) are included in language templates instead of Global/macOS.gitignore CONTRIBUTING.md23-26Sources: README.md37-64 CONTRIBUTING.md7-50
The repository organizes templates into three directories based on popularity, scope, and specificity. This structure balances discoverability with comprehensive coverage README.md19-21
/)/Global/)/community/)Sources: README.md19-35 README.md69-92 Global/README.md1-11
All contributions must include comprehensive context to facilitate review. The repository maintains high standards because maintainers may not be familiar with every technology submitted CONTRIBUTING.md7-9
As defined in the `.github/PULL_REQUEST_TEMPLATE.md1-21 every PR must provide:
| Requirement | Purpose | Code Reference |
|---|---|---|
| Project Homepage | Link to the application or project's official site | CONTRIBUTING.md7-9 |
| Reason for Change | Background on why this change applies to everyone using the tech | CONTRIBUTING.md11-15 |
| Documentation Links | Canonical docs supporting the specific rule changes | CONTRIBUTING.md17-18 |
| Limited Scope | PR must only modify one template at a time | CONTRIBUTING.md28-29 |
main branch README.md114-122Sources: CONTRIBUTING.md1-50 README.md114-129 .github/PULL_REQUEST_TEMPLATE.md1-33
Frameworks and tools that change significantly between versions require a specific versioning strategy to serve both current and legacy users README.md71-72
community/ and must embed the version in the filename for readability README.md77-79community/PHP/Magento1.gitignore recommends using the root Magento.gitignore for the latest version community/PHP/Magento1.gitignore1-3Sources: README.md69-83 community/PHP/Magento1.gitignore1-46
Specialized templates serve niche frameworks or tools that provide value to specific communities but aren't considered mainstream enough for the root directory README.md86-89
All specialized templates must follow a standardized documentation format in the file header:
The community/Alteryx.gitignore file illustrates these standards by including:
Specialized templates should not duplicate rules found in mainstream templates. Instead, they must list recommended base templates in the header README.md90-92
Node.gitignore community/JavaScript/Vue.gitignore1-3VisualStudio.gitignore README.md100Sources: README.md84-112 community/Alteryx.gitignore1-44 community/JavaScript/Vue.gitignore1-10
The maintainers evaluate contributions based on the criteria outlined in CONTRIBUTING.md.
| Factor | Evaluation Criteria |
|---|---|
| Documentation | Does it provide homepage and canonical documentation links? CONTRIBUTING.md7-18 |
| Rationale | Is there a clear explanation of why these files should be ignored for everyone? CONTRIBUTING.md11-15 |
| Granularity | Are the rules added to the most specific and appropriate template? CONTRIBUTING.md21-26 |
| Quality | Is the rule set curated or just a dump of an ls command? CONTRIBUTING.md41-44 |
Templates may be promoted from community/ to the root folder at a later date based on community interest and visibility README.md56-58
Sources: README.md52-64 CONTRIBUTING.md1-50 .github/PULL_REQUEST_TEMPLATE.md22-33
Refresh this wiki