@@ -18,10 +18,47 @@ the following resources are a great place to start:
1818
1919## Folder structure
2020
21- The files in the root directory are for ` .gitignore ` templates that are
22- project-specific, such as language or framework specific templates.
23- Global (operating system or editor specific) templates should go into the
24- [ ` Global/ ` ] ( ./Global ) directory.
21+ We support a collection of templates, organized in this way:
22+
23+ - the root folder contains templates in common use, to help people get started
24+ with popular programming languages and technologies. These define a meaningful
25+ set of rules to help get started, and ensure you are not committing
26+ unimportant files into your repository
27+ - [ ` Global ` ] ( ./Global ) contains templates for various editors, tools and
28+ operating systems that can be used in different situations. It is recommended
29+ that you either [ add these to your global template] ( https://help.github.com/articles/ignoring-files/#create-a-global-gitignore )
30+ or merge these rules into your project-specific templates if you want to use
31+ them permanently.
32+ - [ ` community ` ] ( ./community ) contains specialized templates for other popular
33+ languages, tools and project, which don't currently belong in the mainstream
34+ templates. These should be added to your project-specific templates when you
35+ decide to adopt the framework or tool.
36+
37+ ## What makes a good template?
38+
39+ A template should contain a set of rules to help Git repositories work with a
40+ specific programming language, framework, tool or environment.
41+
42+ If it's not possible to curate a small set of useful rules for this situation,
43+ then the template is not a good fit for this collection.
44+
45+ If a template is mostly a list of files installed by a particular version of
46+ some software (e.g. a PHP framework), it could live under the ` community `
47+ directory. See [ versioned templates] ( #versioned-templates ) for more details.
48+
49+ If you have a small set of rules, or want to support a technology that is not
50+ widely in use, and still believe this will be helpful to others, please read the
51+ section about [ specialized templates] ( #specialized-templates ) for more details.
52+
53+ If you believe your template is important and should be highly visible, please
54+ add details about the impact of the technology when you open a pull request. We
55+ may not accept it immediately, but we can promote it to the root at a later date
56+ based on interest.
57+
58+ Please also understand that we can’t list every tool that ever existed.
59+ Our aim is to curate a collection of the _ most common and helpful_ templates,
60+ not to make sure we cover every project possible. If we choose not to
61+ include your language, tool, or project, it’s not because it’s not awesome.
2562
2663## Contributing guidelines
2764
@@ -39,29 +76,64 @@ high quality, we request that contributions adhere to the following guidelines.
3976
4077- ** Explain why you’re making a change** . Even if it seems self-evident, please
4178 take a sentence or two to tell us why your change or addition should happen.
42- It’s especially helpful to articulate why this change applies to * everyone *
79+ It’s especially helpful to articulate why this change applies to _ everyone _
4380 who works with the applicable technology, rather than just you or your team.
4481
4582- ** Please consider the scope of your change** . If your change is specific to a
4683 certain language or framework, then make sure the change is made to the
4784 template for that language or framework, rather than to the template for an
4885 editor, tool, or operating system.
4986
50- - ** Please only modify * one template * per pull request** . This helps keep pull
87+ - ** Please only modify _ one template _ per pull request** . This helps keep pull
5188 requests and feedback focused on a specific project or technology.
5289
5390In general, the more you can do to help us understand the change you’re making,
5491the more likely we’ll be to accept your contribution quickly.
5592
56- If a template is mostly a list of files installed by a particular version of
57- some software (e.g. a PHP framework) then it's brittle and probably no more
58- helpful than a simple ` ls ` . If it's not possible to curate a small set of
59- useful rules, then the template might not be a good fit for this collection.
93+ ## Versioned templates
6094
61- Please also understand that we can’t list every tool that ever existed.
62- Our aim is to curate a collection of the * most common and helpful* templates,
63- not to make sure we cover every project possible. If we choose not to
64- include your language, tool, or project, it’s not because it’s not awesome.
95+ Some templates can change greatly between versions, and if you wish to contribute
96+ to this repository we need to follow this specific flow:
97+
98+ - the template at the root should be the current supported version
99+ - the template at the root should not have a version in the filename (i.e.
100+ "evergreen")
101+ - previous versions of templates should live under ` community/ `
102+ - previous versions of the template should embed the version in the filename,
103+ for readability
104+
105+ This helps ensure users get the latest version (because they'll use whatever is
106+ at the root) but helps maintainers support older versions still in the wild.
107+
108+ ## Specialized templates
109+
110+ If you have a template that you would like to contribute, but it isn't quite
111+ mainstream, please consider adding this to the ` community ` directory under a
112+ folder that best suits where it belongs.
113+
114+ The rules in your specialized template should be specific to the framework or
115+ tool, and any additional templates should be mentioned in a comment in the
116+ header of the template
117+
118+ For example, this template might live at ` community/DotNet/InforCRM.gitignore ` :
119+
120+ ```
121+ # gitignore template for InforCRM (formerly SalesLogix)
122+ # website: https://www.infor.com/product-summary/cx/infor-crm/
123+ #
124+ # Recommended: VisualStudio.gitignore
125+
126+ # Ignore model files that are auto-generated
127+ ModelIndex.xml
128+ ExportedFiles.xml
129+
130+ # Ignore deployment files
131+ [Mm]odel/[Dd]eployment
132+
133+ # Force include portal SupportFiles
134+ !Model/Portal/*/SupportFiles/[Bb]in/
135+ !Model/Portal/PortalTemplates/*/SupportFiles/[Bb]in
136+ ```
65137
66138## Contributing workflow
67139
0 commit comments