Reputation: 2026
I've done a gsutil rsync before, which included a lot of ".DS_Store" files that I didn't want to sync. Now I would like to get rid of them, but I can't seem to find a way of doing that.
The command I though would work is:
gsutil rm gs://my-bucket/\*.DS_Store\*
However, I'm getting an error stating "CommandException: No URLs matched:" when using this.
Upvotes: 4
Views: 2781
Reputation: 12145
This should do it:
gsutil -m rm -r gs://my-bucket/**/.DS_Store
Or with zsh
gsutil -m rm -r 'gs://my-bucket/**/.DS_Store'
Upvotes: 4