A collection of useful .gitignore templates
★ 176,304⑂ 82,018👁 3,363⑃ 4,811● 0▤ 0◈ 9
176,304
stars
+92
82,018
forks
3,363
watchers
4,811
prs
0
issues
0
releases
9
discussions
README
A collection of .gitignore templates This is GitHub’s collection of [.gitignore][man] file templates. We use this list to populate the .gitignore template choosers available in the GitHub.com interface when creating new repositories and files. For more information about how .gitignore files work, and how to use them, the following resources are a great place to start: - The [Ignoring Files chapter][chapter] of the [Pro Git][progit] book. - The [Ignoring Files article][help] on the GitHub Help site. - The [gitignore(5)][man] manual page. [man]: https://git-scm.com/docs/gitignore [help]: https://docs.github.com/en/get-started/git-basics/ignoring-files [chapter]: https://git-scm.com/book/en/v2/Git-Basics-Recording-Changes-to-the-Repository_ignoring [progit]: https://git-scm.com/book Folder structure We support a collection of templates, organized in this way: - The root folder contains templates in common use, to help people get started with popular programming languages and technologies. These define a meaningful set of rules to help get started, and ensure you are not committing unimportant files into your repository. - Global contains templates for various editors, tools and operating systems that can be used in different situations. It is recommended that you either add these to your global template or merge these rules into your project-specific templates if you want to use them permanently. - community contains specialized templates for other popular languages, tools, and projects that don't currently belong in the mainstream templates. These should be added to your project-specific templates when you decide to adopt the framework or tool. What makes a good template? First and foremost, a template contribution must adhere to our Contributing Guidelines. A template should contain a set of rules to help Git repositories work with a specific programming language, framework, tool or environment. If it's not possible to curate a small set of useful rules for this situation, then the template is not a good fit for this collection. If a template is mostly a list of files installed by a particular version of some software (e.g. a PHP framework), it could live under the community directory. See versioned templates for more details. If you have a small set of rules, or want to support a technology that is not widely in use, and still believe this will be helpful to others, please read the section about specialized templates for more details. Include details when opening a pull request if the template is important and visible. We may not accept it immediately, but we can promote it to the root at a later date based on interest. Please also understand that we can’t list every tool that ever existed. Our aim is to curate a collection of the _most common and helpful_ templates, not to make sure we cover every project possible. If we choose not to include your language, tool, or project, it’s not because it’s not awesome.
Discussions
#4918Imagine he strength and knowedge if we stood togeher and ahared knowlege like a pane of glass.0 comments · 2026-09-23#4861Csharp gitignore file2 comments · 2026-05-13#4859Twincat Gitignore0 comments · 2026-05-08#4681Please remove *.vbp from .gitignore, it is not what is described in the comment above it. They are essential files.1 comments · 2025-06-30#4640Adding a Stale Workflow0 comments · 2025-05-21#4631if I made script that is using this repo to generate combo from templates as submodule included as regular repo but actually it is gist?0 comments · 2025-05-13#4629Add .DS_Store to every type of .gitignore file2 comments · 2025-05-03#4616For python, should .ipynb files should be added under the jupyter notebook comment in the template?2 comments · 2025-04-17
相关报道 (7)
理財周刊AI程式碼工具Claude Code資安漏洞 GitHub上千機密外洩2026-11-09動區動趨Claude Code「不再詢問」可能讓密碼上 GitHub,資安公司發現上千組外流2026-11-09cyberqClaude Code 的「不要再問」選項,讓密碼外洩到 1,122 個公開 GitHub 檔案2026-11-07凤凰网科技你点过的Claude Code“不再询问”,可能把数据库密码送上GitHub2026-11-10搜狐网Anthropic 的 Claude Code 设置文件在 GitHub 上泄露敏感信息 |#AI资讯# #Anthropic# #代码泄露#2026-11-09CSDNGitHub Trending日榜解读:模型网关、任务队列与Git备份工程实践2026-11-05CSDN博客手把手教你在VS Code中使用 Git_vscode如何输入git命令2023-09-23
News & coverage (18)
Hacker NewsA Collection of Useful .gitignore Templates▲ 171 · 16 comments · 2010-11-20Hacker NewsInclusive Coding Bot on GitHub▲ 163 · 220 comments · 2022-04-01Hacker Newsgitignore – A collection of useful .gitignore templates▲ 21 · 4 comments · 2022-11-23Hacker NewsDefault .gitignore Files▲ 6 · 0 comments · 2010-11-08Hacker NewsShow HN: Simple gitignore generator on the web – GUItignore▲ 2 · 0 comments · 2025-06-21Crypto BriefingClaude Code leaks over 1,300 secrets into public GitHub repositories2026-11-09Ars TechnicaClaude Code is accidentally exposing secrets all over GitHub2026-11-09noteSecurity measures for AI agents: 3 things to prevent passwords from remaining after selecting 'Don't ask again'2026-11-09notePasswords remain in files when using 'Don't ask again' in Claude Code: The issue of public exposure on GitHub and the results of checking my own environment2026-11-08Martin Cid MagazineClaude Code’s ‘don’t ask again’ left passwords in 1,122 public GitHub files2026-11-08