Git 忽略任何目录中的文件
示例
要忽略任何目录中的文件foo.txt,您只需输入文件名:
foo.txt # matches all files 'foo.txt' in any directory
如果只想在树的一部分中忽略文件,则可以使用**pattern指定特定目录的子目录:
bar/**/foo.txt # matches all files 'foo.txt' in 'bar' and all subdirectories
或者,您可以.gitignore在bar/目录中创建文件。与上一个示例等效,将bar/.gitignore使用以下内容创建文件:
foo.txt # matches all files 'foo.txt' in any directory under bar/
热门推荐
10 新年门口花束祝福语简短
11 盘锦结婚祝福语大全简短
12 父母生日祝福语 简短独特
13 家庭恩爱祝福语简短英文
14 高考俄语祝福语大全简短
15 虎年祝福语 诗句唯美简短
16 生日婚礼祝福语简短精辟
17 虎年喝酒拜年祝福语简短
18 教师闺蜜祝福语简短