spin
spin copied to clipboard
Option to cache files from bindle
Fixes #455.
This feels pretty untidy in places. If anyone has thoughts on how it could be tidied, I'd really appreciate it!
I did wonder about sticking the cache option into the BindleConnectionInfo
so it flowed without changing so many things, but I'm not sure that feels quite right...
Have you seen bindle's (apparent) caching support? https://docs.rs/bindle/latest/bindle/cache/index.html
@lann RED FACE HERE
I had not - thanks! That would certainly be a more desirable way to do this. I'll take a look when I've finished kicking myself.
@lann I had a go with the Bindle cache module. Although it claims to be for both client and server side use, it currently seems to accept only server providers as sources. So, sadly, I think this is a non-starter for now.
This feels pretty untidy in places. If anyone has thoughts on how it could be tidied, I'd really appreciate it!
How about a new BindleLoader
struct with e.g. url
, base_dst
, cache_dir
fields, refactoring some of these functions into methods?