tulul / tululbot

Telegram Bot for Tululness
Apache License 2.0
8 stars 6 forks source link

Use Submodule #9

Closed wazaundtechnik closed 9 years ago

wazaundtechnik commented 9 years ago

And integrate with tulul/tulul-quotes

fushar commented 9 years ago

I don't think this is necessary. From my experience, submodules complicate development. We can just treat tulul-quotes as an external resource.

It's a subjective opinion, though.

wazaundtechnik commented 9 years ago

So if that is the case, how should we implement the /quote command?

I have two proposals:

  1. Use submodule: By default, Heroku will recursively pull the submodule too. And since we have all of the data locally, we can simply read the yml from file.
  2. Use Github API to retrieve that yml file from master branch, cache it at start (or every 5 minutes) to reduce network overhead.

What do you think? So you don't prefer first option?

fushar commented 9 years ago

You can just wget https://raw.githubusercontent.com/tulul/tulul-quotes/master/quote.yaml.

kmkurn commented 9 years ago

+1 @fushar 's idea. If the quote rarely changes, we can even load it once and store it on memory; restarting the app whenever a new quote is added. I think it's simpler.

wazaundtechnik commented 9 years ago

Thanks. Settled. So no submodule for now. If something is changing in the future, feel free to reopen this.