Skip to content

fetch,pull: support literal path arguments - #6327

Open
fzlzjerry wants to merge 1 commit into
git-lfs:mainfrom
fzlzjerry:feat/5946-fetch-pull-paths
Open

fetch,pull: support literal path arguments#6327
fzlzjerry wants to merge 1 commit into
git-lfs:mainfrom
fzlzjerry:feat/5946-fetch-pull-paths

Conversation

@fzlzjerry

Copy link
Copy Markdown
Contributor

Summary

  • allow git lfs fetch and git lfs pull to accept literal file or directory paths after --
  • resolve relative and absolute paths against the repository while preserving filenames containing wildcard characters
  • combine explicit paths with existing fetch include/exclude filters, and reject path filtering with fetch --all
  • document the new syntax and add focused unit and integration coverage

Paths are matched literally rather than as gitignore patterns, so a filename such as literal[1].dat cannot accidentally select literal1.dat. Directory arguments include their descendants, and matching follows core.ignorecase where configured.

Tests

  • make test
  • make -C t test (105 test files, 835 tests)
  • go vet ./commands ./filepathfilter

Closes #5946

@fzlzjerry
fzlzjerry requested a review from a team as a code owner August 13, 2026 14:22
Copilot AI lite review requested due to automatic review settings August 13, 2026 14:22

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add fetch --filename

2 participants