|
1 | 1 | # mattermost-plugin-disable-dm
|
2 | 2 | A mattermost plugin to disable direct messages and group chats.
|
| 3 | + |
| 4 | +## Installation and setup |
| 5 | +#### Platform & tools |
| 6 | +- Make sure you have following components installed: |
| 7 | + |
| 8 | + * Go - v1.11 - https://golang.org/doc/install |
| 9 | + > **Note:** If you have installed Go to a custom location, make sure the $GOROOT variable is set properly. Refer [Installing to a custom location](https://golang.org/doc/install#install). |
| 10 | +
|
| 11 | + * NodeJS - v10.11 and NPM - v6.4.1 - https://docs.npmjs.com/getting-started/installing-node |
| 12 | + |
| 13 | + * Make |
| 14 | + |
| 15 | + |
| 16 | +## Building the plugins |
| 17 | +- Run the following commands to prepare a compiled, distributable plugin zip: |
| 18 | + |
| 19 | +``` |
| 20 | +$ mkdir -p ${GOPATH}/src/github.com/Brightscout |
| 21 | +$ cd ${GOPATH}/src/github.com/Brightscout |
| 22 | +$ git clone [email protected]:Brightscout/mattermost-plugin-disable-dm.git |
| 23 | +$ cd mattermost-plugin-disable-dm |
| 24 | +$ make dist |
| 25 | +``` |
| 26 | + |
| 27 | + |
| 28 | +- This will produce three tar.gz files in `/dist ` directory corresponding to various platforms: |
| 29 | + |
| 30 | +| Flavor | Distribution | |
| 31 | +|-------- | ------------ | |
| 32 | +| Linux | `mattermost-plugin-disable-dm-v<X.Y.Z>-linux-amd64.tar.gz` | |
| 33 | +| MacOS | `mattermost-plugin-disable-dm-v<X.Y.Z>-darwin-amd64.tar.gz` | |
| 34 | +| Windows | `mattermost-plugin-disable-dm-v<X.Y.Z>-windows-amd64.tar.gz` | |
| 35 | + |
| 36 | +This will also install, **Glide** - the Go package manager. |
| 37 | + |
| 38 | +## Install the plugin to Mattermost |
| 39 | +- Make sure that the plugin uploads are enabled in `PluginSettings.EnableUploads` in your `config.json` file. |
| 40 | +- Go to **System Console > Plugins (Beta) > Management** and set `Enable Plugins` to `true`. |
| 41 | +- From **System Console > Plugins (Beta) > Management**, upload the plugin generated above based on the OS of your Mattermost server. |
| 42 | +- Once installed, open **System Console > Plugins (Beta) > Team Membership** in left-hand sidebar and configure the plugin settings. |
| 43 | +- Enable the plugin from **System Console > Plugins (Beta) > Management**. |
0 commit comments