Given that this cli could be useful as a final step in the shell rc configurations (to be greeted with a joke everytime a new terminal is opened), latency is important. Can some form of caching be introduced in this regard? One idea could be to have an init script that needs to be invoked via chuckle init that would download all the jokes and keep it in memory. Invoking it again would simply sync the local state with that has been published already. Whenever chuckle is invoked, a joke is fetched from this list on disk.
Given that this cli could be useful as a final step in the shell rc configurations (to be greeted with a joke everytime a new terminal is opened), latency is important. Can some form of caching be introduced in this regard? One idea could be to have an init script that needs to be invoked via
chuckle initthat would download all the jokes and keep it in memory. Invoking it again would simply sync the local state with that has been published already. Wheneverchuckleis invoked, a joke is fetched from this list on disk.