Repository navigation
Add include/exclude config options & params to fetch - #573
Conversation
These include or exclude lists of paths (matching as per gitignore) in the fetch to optimise downloading.
…n arg If we close down the update-index process without having given it any args in stdin, then it applies to the whole working copy and has unwanted side effects e.g. calling clean/smudge filters.
0997422 to
bf8bade
Compare
|
This PR is safe to merge after #581 |
There was a problem hiding this comment.
Does it make sense to initialize the array with a capacity based on the number of commas in the strings? Not sure this matters much though. Probably best to keep the code simpler :)
There was a problem hiding this comment.
Yeah I figured the likelihood of having enough separate entries to warrant this was quite small.
|
I think this PR looks good 👍 A couple things come to mind that won't necessarily block this PR: As a user, I don't think this documentation is sufficient to show me how this works. What kinds of file paths can I use? Well, I know based on these tests. How should the docs describe this? A man page? Or a link to something in ./docs from the man pages? Related to that, is there a way to get some visibility into what this is doing? If I have some include/exclude properties set without knowing it, the fetch/pull commands may behave unexpectedly. Any thoughts on how we could show what files, if any, are skipped to lfs users? |
|
👍, agree on some more documentation |
Add include/exclude config options & params to fetch
|
The matching/wildcard rules are the same as gitignore (deliberately so); I'm updating the docs for my next PR anyway so I've included some explicit examples: sinbad@e7e150c |
|
@sinbad: That's perfect 👍 |
Note: don't merge until we've resolved #564.
Added
lfs.fetchincludeandlfs.fetchexcludeconfig options and--includeand--excludecommand line args to fetch. These cause certain paths to either be included or excluded when fetching binaries so that people who work in specific subfolders and don't want to waste time or disk space fetching irrelevant things can do so. This is most common in teams using a single shared repo for all assets but where not everyone needs all of them, e.g. only texture artists might need the original .psd files vs exported runtime equivalents, only modellers/animators might need the original .max files etc. Some teams have a more complex pipeline which avoids this but for those that don't wanting to download by subfolder is quite common. I expect the config option variants to be most used,--include/--excludeargs to fetch are there for special occasions.This affects the behaviour of
fetch,pullandsmudgesince in all cases thedownloadargument to PointerSmudge is set based on whether it matches include/exclude filters.There is a later knock-on effect on
pushthough because it means a user won't have all oids for a given commit. Right now that will causepushto fail later if the commits in question get included in the scan for pushing a new branch. This is another case of #564, which needs to be addressed before this can be merged.