Windows Subsystem for Linux 的 .gitignore

适用于 Windows Subsystem for Linux 的 1 条忽略规则,可直接复制到您的仓库。

Windows 上的 Linux 兼容层

Windows Subsystem for Linux 的完整 .gitignore

# 由 LFGitignore - https://lfgitignore.com 生成
# 创建:2026-10-31 21:54:06 UTC
# 技术:Windows Subsystem for Linux

### Windows Subsystem for Linux ###
*:Zone.Identifier

这些 Windows Subsystem for Linux 规则实际上忽略了什么

以下列出了每个忽略模式及其加入 .gitignore 的原因。

通用

模式 忽略的内容
*:Zone.Identifier 通用

如何将此 .gitignore 用于 Windows Subsystem for Linux

  1. 复制上面的Windows Subsystem for Linux规则,或者直接下载文件。
  2. 在 Git 仓库根目录创建名为 .gitignore 的文件,并将规则粘贴进去。
  3. 如果其中一些文件已被跟踪,请运行 git rm -r --cached . 然后再次提交 - Git 仅将忽略规则应用于未跟踪的文件。
  4. 提交 .gitignore 以便团队中的每个人都共享相同的规则。

其他 操作系统 .gitignore 模板

查看每个 操作系统 模板