简体   繁体   中英

DVC remove unused file from remote repository S3

I'm trying to remove 1 file from S3 remote repository which is no longer tracked by DVC.

So, I did:

  • dvc remove.dvc file
  • git add & commit the.gitignore and.dvc files
  • run dvc gc -c --workspace

however, the process of deleting 1 file (13KB) took 6 minutes, is that normal or is there a step I'm missing?

here's the details for dvc gc -c --workspace :

delete process img1

delete process img2

reference: https://dvc.org/doc/command-reference/gc

From the dvc gc documentation :

-w, --workspace - keep only files and directories referenced in the workspace. 
This option is enabled automatically with the other scope options (below).

It means that this command removes all the files except those that are still in use (referenced) in the workspace and only in the workspace.

In your case this command would remove data that belongs to the previous commits in the repo. This might be taking time.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM