Irev-Dev / cadhub

We're out to raise awareness and put CodeCAD on the map. The success of CadHub can be measured by the amount it promotes the use of CodeCAD within the mechanical/manufacturing industry and the strength the CadHub community.
https://cadhub.xyz
GNU General Public License v3.0
319 stars 60 forks source link

Discord chat bot to announce projects #590

Closed smartin015 closed 2 years ago

smartin015 commented 2 years ago

Closes #589

This adds support for a Discord bot that announces when interesting things happen on the backend. It's currently set up to notify when someone saves a new project image, as a proxy for "done-ness" to the point where folks might want to take a look and comment on the project. It has some limitations to keep the usage simple - it only sends text, and only to a single channel configured on startup (see .env.defaults). However, the bot (and lib) could very easily be modified to do more advanced stuff, e.g. responding to user chats from Discord.

While I was able to successfully set up a bot and have it talk on a channel, this PR isn't quite complete:

Screenshot from 2022-01-09 16-10-11

Irev-Dev commented 2 years ago

This looks really promising 🚀 , I'll respond to you properly after work.

Irev-Dev commented 2 years ago

I made a PR to this PR haha, https://github.com/smartin015/cadhub/pull/1 (I don't like stomping on other people's branches with my commits)

I think this is ready if you are happy with the changes I made, here's what the messages look like with the image.

image

smartin015 commented 2 years ago

Yeah, this looks great! Ready to merge when you are.