templates

.gitignore templates

All 312 templates from github/gitignore, plus rule-by-rule explanations of 30 popular ones. Click a name to open it in the generator.

Popular templates, explained

Node

A rule-by-rule explanation of why Node.gitignore ignores node_modules, logs, build output, .env and tool caches, plus notes on lockfiles and Yarn Berry.

Python

Why Python.gitignore ignores __pycache__, virtual environments, packaging output, test and type-checker caches and secret settings, with notes on lib/ and lockfiles.

Java

Why Java.gitignore ignores .class files, package archives (jar, war) and JVM crash logs, and the ordering issue when combining it with build-tool templates.

Go

Why Go.gitignore ignores binaries, test binaries, coverage profiles and go.work, and why extensionless executables need a separate rule.

Rust

Why Rust.gitignore ignores the target directory, rustfmt backups, MSVC debug info and cargo-mutants output, and the change to recommend committing Cargo.lock.

C

Why C.gitignore ignores object files, static and shared libraries, executables, debug info and Linux kernel module build files.

C++

Why C++.gitignore ignores objects, libraries and executables, CMake build trees, compile_commands.json and the vcpkg install folder, and the pitfall of the Makefile rule.

VisualStudio

Why VisualStudio.gitignore ignores the .vs folder, per-user settings, Debug/Release output, NuGet packages, test results and publish profiles.

Swift

Why Swift.gitignore ignores xcuserdata, app packaging files, Swift Package Manager's .build, Carthage builds and fastlane output, and how to decide on CocoaPods and Package.resolved.

Kotlin

Why Kotlin.gitignore ignores JVM output such as .class and jar files and the Kotlin 2.0 .kotlin directory, and what to watch for when combining it with the Gradle and Android templates.

Flutter

Why Flutter.gitignore ignores .dart_tool, build, platform-specific generated files and signing keys, and the problem of the *.lock rule also blocking pubspec.lock.

Android

Why Android.gitignore ignores Gradle caches, build output, local.properties, APK/AAB, .idea, signing keystores and google-services.json, and how to decide.

Unity

Why Unity.gitignore ignores Library, Temp, Obj, Build, Logs, UserSettings and auto-generated IDE files, and why .meta files must always be committed.

UnrealEngine

Why UnrealEngine.gitignore ignores Binaries, Intermediate, Saved, DerivedDataCache and generated solution files, and how the negation rules for the Build folder work.

Ruby

Why Ruby.gitignore ignores gem packages, Bundler install folders, test results and generated docs, and when to commit Gemfile.lock and .ruby-version.

Rails

Why Rails.gitignore ignores log, tmp and storage, the development SQLite database, master.key, precompiled assets and node_modules, and how the .keep negation structure works.

Laravel

Why Laravel.gitignore ignores vendor, node_modules, .env, the public/storage symlink, Vite builds, Passport keys and auth.json.

Terraform

Why Terraform.gitignore ignores the .terraform folder, tfstate, tfvars, override files and CLI config, and why .terraform.lock.hcl must be committed.

Gradle

How Gradle.gitignore ignores the .gradle and build folders while using negation patterns to restore build folders under src and the Gradle wrapper jar.

Maven

Why Maven.gitignore ignores the target folder, release plugin backups, shade plugin output, the Maven wrapper jar and Eclipse files.

Nextjs

Why Nextjs.gitignore ignores .next, out, node_modules, .env files, .vercel, next-env.d.ts and *.pem, and how it differs from the Node template.

Angular

Why Angular.gitignore ignores dist, the .angular cache, out-tsc and coverage, and when to remove the rules that ignore lockfiles (package-lock.json, yarn.lock).

Dotnet

Why Dotnet.gitignore ignores bin and obj, Debug and Release, NuGet packages, MSBuild binary logs, test results and .env, and how it differs from the VisualStudio template.

JupyterNotebooks

Why JupyterNotebooks.gitignore ignores .ipynb_checkpoints, IPython profiles and .virtual_documents, and how to manage notebook output.

macOS

Why macOS.gitignore ignores .DS_Store, ._ resource forks, Icon files, and Spotlight, Time Machine and Trash folders, and how to put it in a global gitignore.

Windows

Why Windows.gitignore ignores Thumbs.db, desktop.ini, $RECYCLE.BIN, installer packages and shortcut files, with notes on case sensitivity and global settings.

Linux

Why Linux.gitignore ignores editor backups (*~), FUSE and NFS temporary files, KDE .directory, Trash folders and nohup.out.

VisualStudioCode

Why VisualStudioCode.gitignore excludes the folder contents with .vscode/* and restores the settings, tasks, launch and extensions files with negation patterns, and what to share.

JetBrains

Why JetBrains.gitignore ignores only personal settings and sensitive files in the .idea folder of IntelliJ, PyCharm, WebStorm and others, and how that differs from ignoring all of .idea.

Vim

A step-by-step look at Vim.gitignore's swap file bracket pattern ([._]*.s[a-v][a-z]), the !*.svg exception, and the session, undo and tags rules.

Popular combos

Node + macOS + VS Code

Node, macOS, VisualStudioCode

Next.js + Node + macOS

Nextjs, Node, macOS, VisualStudioCode

Python + macOS + VS Code

Python, macOS, VisualStudioCode

Python + Jupyter

Python, JupyterNotebooks, macOS

Java + Maven + IntelliJ

Java, Maven, JetBrains, macOS

Android + Kotlin + IntelliJ

Android, Kotlin, Gradle, JetBrains, macOS

Flutter + Dart

Flutter, Dart, VisualStudioCode, macOS

Go + JetBrains

Go, JetBrains, Linux

Rust + VS Code

Rust, VisualStudioCode, macOS

Rails + Ruby

Rails, Ruby, macOS

Laravel + PHP

Laravel, Composer, JetBrains, macOS

.NET + Visual Studio

VisualStudio, Dotnet, Windows

Unity + Visual Studio

Unity, VisualStudio, Windows, macOS

Terraform + VS Code

Terraform, macOS, VisualStudioCode

Languages & frameworks (163)

OS, editors & tools (76)

Community (73)

Templates from github/gitignore @356fd7b (2026-09-11) · CC0-1.0