# Discourse Mingle

**URL:** <https://meta.discourse.org/t/discourse-mingle/95634>\
**Category:** Plugin\
**Tags:** broken\
**Created:** [August 25, 2018, 5:44pm UTC](https://meta.discourse.org/t/discourse-mingle/95634 "2018-08-25T17:44:46Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![gdpelican](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gdpelican/32/81308_2.png) [@gdpelican](https://meta.discourse.org/u/gdpelican)\
**Post date:** [August 25, 2018, 5:44pm UTC](https://meta.discourse.org/t/discourse-mingle/95634/1 "2018-08-25T17:44:46Z")

</div>

Mingle is an icebreaker 🏔 🔨 plugin for Discourse, inspired by [the Donut slackbot](https://www.donut.com/) and originally discussed [here](https://meta.discourse.org/t/making-random-connections-within-a-community/95434). [Hi @debryc!]

[https://github.com/gdpelican/mingle](https://github.com/gdpelican/mingle)

### 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](https://meta.discourse.org/t/install-plugins-in-discourse/19157)

- **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 `mingle_group_name`:

- 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 :fonzie:, you can get the original template back by running

```plaintext
/var/discourse/launcher enter app
rails c
Mingle::Initializer.new.reinitialize!

```

### Contributing

#### Bug reports

This is currently a **beta plugin** (I wrote it yesterday 🥳), so please give it a go and report any troubles by mentioning me (@gdpelican) in this topic or in the [issues list](http://github.com/gdpelican/mingle/issues).

#### Code

- Fork it (`https://github.com/[my-github-username]/mingle/fork`)
- 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 ?”)

---

_[View the full topic](https://meta.discourse.org/t/discourse-mingle/95634)._
