workers-sdk icon indicating copy to clipboard operation
workers-sdk copied to clipboard

🚀 Feature Request: Do Not Delete Assets On Upload (Allow Multiple "Folders")

Open jjjrmy opened this issue 3 years ago • 0 comments

Describe the solution

I'd like to be able to upload to "folders" inside of KV, and only delete/replace the ones from that project.

For example: I have multiple repositories for component libraries that compile to 2 files (usually), a JS and CSS file. I'd like to have them uploaded to to same KV like <reponame>/<filename>.

Currently when you publish it will diff all the files and delete the ones not included in that upload. I'd like a flag to only replace certain files, maybe by a regex for keys or a "folder".

So I could have my files like theme1/theme.js and anothertheme/theme.js all in the same KV, and only overwrite/replace the files in theme1 "folder" when I re-publish that repo.

That way I won't have to deal with a bunch of KVs bound to my worker with only a few files each.

jjjrmy avatar Sep 01 '22 17:09 jjjrmy