Skip to content

import: git sparse-checkout #3438

@casperdcl

Description

@casperdcl

dvc import https://some/git/repo/ some_file should probably do a sparse checkout.

Currently looks like it does a full clone:

https://github.com/iterative/dvc/blob/05cc023164766fbbec91642d7d8af513c8d4079b/dvc/stage.py#L941 would call https://github.com/iterative/dvc/blob/05cc023164766fbbec91642d7d8af513c8d4079b/dvc/dependency/repo.py#L73-L81

On a related note, is the repo locally cached by default https://github.com/iterative/dvc/blob/05cc023164766fbbec91642d7d8af513c8d4079b/dvc/dependency/repo.py#L78-L79 so that dvc update won't re-clone?

Metadata

Metadata

Assignees

Labels

enhancementEnhances DVCp2-mediumMedium priority, should be done, but less importantperformanceimprovement over resource / time consuming tasks

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions