netlify-plugin-cache icon indicating copy to clipboard operation
netlify-plugin-cache copied to clipboard

Cache all files, folders, sub-folders within a directory

Open jeremyzilar opened this issue 4 years ago • 4 comments

So I am looking to cache a lot of the files we rarely touch in our site... most of which exist in static/media/files/. Our site runs on HUGO. Here is the repo: https://github.com/brooklynrail/brooklynrail-platform

But when I add the path to the plugin

[[plugins]]

  package = "netlify-plugin-cache"
    [plugins.inputs]
    paths = ["public", "static/media/files"]

The number of files that Netlify says it has cached between both paths is around 22, which is odd since there are more than 22 files in those folders. I think it might be counting the folders directly below each?

Should I be specifying all files within this dir, like static/media/files/*?

jeremyzilar avatar Nov 27 '20 19:11 jeremyzilar

I'm running into this same issue, it says 2 files, there are 100s..

nijotz avatar Dec 09 '21 05:12 nijotz

Same issue here

joebailey26 avatar Jun 13 '23 16:06 joebailey26

Actually, it displays the number of directories cached, not separate files:

image

In the case in picture, it means that node_modules and assets/.cache/ were cached. You can ignore this behavior as long as the cache restores as expected

maddsua avatar Jun 13 '23 17:06 maddsua

Thanks, I did some more debugging and found the same thing.

joebailey26 avatar Jun 13 '23 21:06 joebailey26