Skip to content

Allow downloading a single file by project name without a local checkout - #318

Open
varmar05 wants to merge 1 commit into
masterfrom
single_file_download
Open

Allow downloading a single file by project name without a local checkout#318
varmar05 wants to merge 1 commit into
masterfrom
single_file_download

Conversation

@varmar05

@varmar05 varmar05 commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Existing download files interface is extended to support both local checkout folder or just destination. In the latter case no project checkout is needed to download single file in particular version.

Closes #210

@varmar05
varmar05 requested a review from MarcelGeo September 3, 2026 06:06
@coveralls

Copy link
Copy Markdown

Coverage Report for CI Build 33721706674

Coverage decreased (-0.04%) to 83.351%

Details

  • Coverage decreased (-0.04%) from the base build.
  • Patch coverage: 10 uncovered changes across 2 files (46 of 56 lines covered, 82.14%).
  • 1 coverage regression across 1 file.

Uncovered Changes

File Changed Covered %
mergin/cli.py 9 0 0.0%
mergin/client_pull.py 25 24 96.0%
Total (3 files) 56 46 82.14%

Coverage Regressions

1 previously-covered line in 1 file lost coverage.

File Lines Losing Coverage Coverage
mergin/client_pull.py 1 82.76%

Coverage Stats

Coverage Status
Relevant Lines: 5718
Covered Lines: 4766
Line Coverage: 83.35%
Coverage Strength: 0.83 hits per line

💛 - Coveralls

Comment thread mergin/client.py
Download project files at specified version. Get the latest if no version specified.

:param project_dir: project local directory
:param project_dir: project local directory or a full project name ("<workspace>/<project>")

@MarcelGeo MarcelGeo Sep 4, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We can probably use same pattern as project name in cli. This is like mix of multiple behaviours in one arg. We could probably use also separated method in client.py download_project_file or similar.

This could be in future path like type.

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 API call to download one file

3 participants