xref: /linux/.gitignore (revision aec2f682d47c54ef434b2d440992626d80b1ebdc)
1# SPDX-License-Identifier: GPL-2.0-only
2#
3# NOTE! Don't add files that are generated in specific
4# subdirectories here. Add them in the ".gitignore" file
5# in that subdirectory instead.
6#
7# NOTE! Please use 'git ls-files -i -c --exclude-per-directory=.gitignore'
8# command after changing this file, to see if there are
9# any tracked files which get ignored after the change.
10#
11# Normal rules (sorted alphabetically)
12#
13.*
14*.a
15*.asn1.[ch]
16*.bc
17*.bin
18*.bz2
19*.c.[012]*.*
20*.dt.yaml
21*.dtb
22*.dtbo
23*.dtb.S
24*.dtbo.S
25*.dwo
26*.dylib
27*.elf
28*.gcno
29*.gcda
30*.gz
31*.i
32*.ko
33*.lex.c
34*.ll
35*.lst
36*.lz4
37*.lzma
38*.lzo
39*.mod
40*.mod.c
41*.o
42*.o.*
43*.patch
44*.pyc
45*.rlib
46*.rmeta
47*.rpm
48*.rsi
49*.s
50*.so
51*.so.dbg
52*.su
53*.symtypes
54*.tab.[ch]
55*.tar
56*.xz
57*.zst
58Module.symvers
59dtbs-list
60modules.order
61
62#
63# Top-level generic files
64#
65/linux
66/modules-only.symvers
67/vmlinux
68/vmlinux.32
69/vmlinux.map
70/vmlinux.symvers
71/vmlinux.unstripped
72/vmlinux-gdb.py
73/vmlinuz
74/System.map
75/Module.markers
76/modules.builtin
77/modules.builtin.modinfo
78/modules.builtin.ranges
79/modules.nsdeps
80
81#
82# RPM spec file (make rpm-pkg)
83#
84/rpmbuild/
85
86#
87# Debian directory (make deb-pkg)
88#
89/debian/
90
91#
92# Snap directory (make snap-pkg)
93#
94/snap/
95
96#
97# tar directory (make tar*-pkg)
98#
99/tar-install/
100
101#
102# pacman files (make pacman-pkg)
103#
104/PKGBUILD
105/pacman/
106
107#
108# We don't want to ignore the following even if they are dot-files
109#
110!.clang-format
111!.clippy.toml
112!.cocciconfig
113!.editorconfig
114!.get_maintainer.ignore
115!.gitattributes
116!.gitignore
117!.kunitconfig
118!.mailmap
119!.pylintrc
120!.rustfmt.toml
121
122#
123# Generated include files
124#
125/include/config/
126/include/generated/
127/arch/*/include/generated/
128
129# stgit generated dirs
130patches-*
131
132# quilt's files
133patches
134series
135
136# ctags files
137tags
138!tags/
139TAGS
140
141# cscope files
142cscope.*
143ncscope.*
144
145# gnu global files
146GPATH
147GRTAGS
148GSYMS
149GTAGS
150
151# id-utils files
152ID
153
154*~
155\#*#
156
157#
158# Leavings from module signing
159#
160extra_certificates
161signing_key.pem
162signing_key.priv
163signing_key.x509
164x509.genkey
165
166# Kconfig presets
167/all.config
168/alldef.config
169/allmod.config
170/allno.config
171/allrandom.config
172/allyes.config
173
174# Kconfig savedefconfig output
175/defconfig
176
177# Kdevelop4
178*.kdev4
179
180# Clang's compilation database file
181compile_commands.json
182
183# Documentation toolchain
184sphinx_*/
185
186# Rust analyzer configuration
187/rust-project.json
188
189# bc language scripts (not LLVM bitcode)
190!kernel/time/timeconst.bc
191