Two use cases I can think of here:
- cache the result of a network call (i.e. ListObjects) that takes a second or two for subsequent commands
- cache the user's previous flag inputs
Random ideas:
- provide a helper function that makes the slow call and manipulates with with gojq to get the completions with a TTL
- need to respect secrets and not cache those
- probably an interface for the storage and plug in SQLite + JSON heirarchy
- cache key is (part of) warg.Context so need to serialize (part of) that somehow
Two use cases I can think of here:
Random ideas: