Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

GCS - Deletion of object but not a folder object only files inside a folder object

Currently we have GCS Buckets and each GCS Bucket have a folder inside and actual data files are inside the folder. 

We wanted to cleanup those data files but not the folders. We want to retain the folders. 

Recently GCP launched MatchesPrefix option in Lifecyle policy which can be applied at Object level however when I apply a lifecycle policy it cleans both Folder as well as Data File Inside the folder.

Is there any better way to retain the folder and delete the data files using LiveCycle policy option such MatchesPrefix/MatchesSuffix?

1 16 9,310