Git LFS递归跟踪文件夹 [英] Git LFS track folder recursively

查看:701
本文介绍了Git LFS递归跟踪文件夹的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以使用Git LFS递归跟踪文件夹及其子文件夹中包含的所有文件?

Is it possible to track recursively all files contained in a folder and its subfolders with Git LFS ?

我想做这样的事情:

git lfs track myfolder/*

推荐答案

使用git lfs track "myfolder/**"(带引号)可避免Shell已经扩展了模式. track命令的全部作用是写入.gitattributes,而.gitattributes反过来使用(几乎)与.gitignore相同的模式匹配规则,请参见

Use git lfs track "myfolder/**", with quotes to avoid the shell already expanding the pattern. All that the track command does is to write to .gitattributes, which in turn uses (almost) the same pattern matching rules as .gitignore, see the PATTERN FORMAT description.

这篇关于Git LFS递归跟踪文件夹的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆