How it works
Specify a time period (e.g. 2 weeks), a group of users, and a customizable message.
Once per time period, we’ll randomly pair up people in the group, and send them a friendly private message, inviting them to get to know each other a little better.
What to do
In order to set up a Mingle, follow these four steps:
Install the plugin by following your normal plugin installation instructions
Visit the Mingle settings panel at
<yoursite.com>/admin/site_settings/category/all_results?filter=mingle. Select a group, setup a time period, and select a user to send the message. Mingle is disabled by default to ensure that you set things up the way you want, so be sure to enable it once you’re ready.
Visit the #staff category; you should see a new topic there, with ‘Mingle’ in the title. This is the template for your message! Click into it, read the instructions, and customize a message to send to your users.
You’re done! The first message will go out in the specified time period, and a new one will be scheduled once it’s sent.
Other things you can do
Note that you can specify multiple groups to mix by using the following format for
You can also change the size of the groups people are placed in (default is pairs), by changing the ‘Mingle group size’ option.
If you’d like to set a specific time for when the next match will happen, you can do so by clicking on ‘change’ next to the next scheduled run time; If you modify either the interval type or interval number (for example, changing from 3 to 4 weeks, or 3 days to 3 weeks), Mingle will automatically reschedule the existing job for the specified time interval.
If things go weird
- You can view the next scheduled Mingle in your sidekiq queue at
<yoursite.com>/sidekiq/scheduled; it’s the one called
Jobs::Mingle. Adding it to the queue will perform it immediately, and schedule another one in the future.
- If you end up without a scheduled job there somehow, simply disable and then re-enable the Mingle plugin, and it should come back
- To stop scheduling Mingles, simply disable the mingle_enabled setting (this will kill the currently scheduled Mingle as well)
- If you’ve mangled your template beyond repair , you can get the original template back by running
/var/discourse/launcher enter app rails c Mingle::Initializer.new.reinitialize!
- Fork it (
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create a new pull request
- Be an awesome open source contributor!
Stuff that could happen next
- Right now the matches are completely random, but maybe there’s a more better way, taking into account whether a particular pair has been matched before, whether they’re a seasoned veteran vs a newbie, etc.
- Currently if there’s an odd number of people in the group, one person is ‘left out’ for each set of matches. It would be nice to add that person to a three-person message, or otherwise do something other than ignore them.
- I think we may need support for a ‘default’ thing to put in the template if, for example, a user doesn’t have a particular custom field set (right now it will just put in the empty string, which could make for weird sentences like “Did you know that Flynn ?”)