This repository was archived by the owner on Jan 2, 2025. It is now read-only.
Allow quick & shallow copies of Git repos to select which repos to index#1115
Merged
Allow quick & shallow copies of Git repos to select which repos to index#1115
Conversation
Collaborator
|
I tried it with your example query and also with the reverse one (exclude_file and exclude_regex) and as far as I can see it doesn't index anything by default and only files in 'include_regex' and 'include_file' were indexed. In the case of exclude_file and exclude_regex nothing was indexed at all. Can we change that so that everything is included by default and the user will use 'exclude_' fields to ignore some files and folders? |
anastasiya1155
approved these changes
Nov 7, 2023
oppiliappan
approved these changes
Nov 9, 2023
Contributor
oppiliappan
left a comment
There was a problem hiding this comment.
code changes look good to me, will give this a test.
70d7895 to
e2445b5
Compare
ggordonhall
reviewed
Nov 21, 2023
We don't need the other criterion, as the callee function will hit the db to determine if there's work to be done.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Initiate the clone with:
This will create a shallow clone (1 commit depth), and a fast index of the repository in question, without looking at the body of any of the files.
After this process is done, the repository ends up in a
Shallowstate, which means it won't automatically be refreshed until the file filters are configured.To configure file filters, use the following call:
The first call to this will automatically create a Git clone of 1000 commits in depth, and allows syncing the repo fully with the configured file filters.
Note that file filters are additive, and prioritise inclusion over exclusion. In other words, once something's been added to the index, can't be marked to be removed from the index without removing the repository completely!