WordPress / five-for-the-future

Plugins and themes for the Five for the Future subsite
https://wordpress.org/five-for-the-future/
54 stars 25 forks source link

Noting milestone contributions #203

Open angelasjin opened 2 years ago

angelasjin commented 2 years ago

I'm not sure how this might be already done, so any notes would be helpful!

I think it would be fun and encouraging to see milestones in contributions, for example:

You get the idea :) What would it take to do something like this?

courtneyr-dev commented 2 years ago

Those milestones might be handy to also share to those managing badges for their teams. I know some teams set a total, like support forums is 400 replies unrelated to your own plugins. That earns a contributor badge.

iandunn commented 2 years ago

That should be doable. The implementation details would probably depend on exactly what the milestones are, and may need to be different for different milestones.

In general though, a cron job could run daily and count the # of specified activities for each user, then add a profile entry if it's at the milestone. Then it'd update usermeta with a note that they reached that milestone, so that tomorrow's cron job doesn't add a duplicate notification.

We might need to start saving some additional meta data in some cases, but it'll depend on the exact milestones.

Related to #189 since it may use that data a bit, cc @StevenDufresne as FYI