Giter VIP home page Giter VIP logo

mattermost-plugin-messages-queue's Introduction

Mattermost Message Queue

This plugin adds async messages delivery based on time or online status of the users through /defer-post and /messages-queue slash commands.

/defer-post

The /defer-post commands that allows to defer the delivery of a message for certain amount of time, or until the other user is online (in DMs).

Available commands

  • /defer-post [time] [message] - Send the message after the time has passed
  • /defer-post online [message] - Send the message when the user is online (only valid for DMs)

Defer time format

The time can be specified in the golang format that you can see here.

Examples

  • In a DM you can run /defer-post online please take a look at this ticket #123. That will send the message to the user whenever the user is online again, so you don't have to worry about annoying him while he is offline (no message, and no notifications).
  • In any channel you can run /defer-post 2h Starting the deployment. This will schedule the message to be sent in 2 hours.

/messages-queue

The /messages-queue commands allows you to create and maintain messages queues that are sent based on a schedule.

You can list, add and delete queues, and the messages in it. Every time the scheduled message queue is triggered, it sends one message from the queue. So if you have a queue with 20 messages, and your schedule is to run it every day, is going to take 20 days to send all the messages.

When the queue is empty, no messsage is sent.

Available commands

  • /messages-queue create <name> <schedule> - Create a queue for the current channel (see the Schedule format help at the bottom)
  • /messages-queue list - List the queues for this channel
  • /messages-queue delete <queue-name> - Delete a queue.
  • /messages-queue add-message <queue-name> <message> - Add a new message to the queue
  • /messages-queue list-messages <queue-name> - Add a new message to the queue
  • /messages-queue remove-message <queue-name> <position> - Remove a message from the queue in the specified position
  • /messages-queue insert-message <queue-name> <position> <message> - Add a new message to the queue in the specified position

Schedule format

The schedule format used is the cron expression format, you can see more information here.

Example

  • If you want to prepare a set of tips to send them from monday to friday at 10 am to your users you can run:
    • /message-queue create tips 0 10 * * 1-5
    • /message-add-message tips remember to take some breaks during the day.
    • /message-add-message tips remember to send your standup summary to the standup channel.
    • /message-add-message tips Do you know you can expense books and learning material? Please do it!

mattermost-plugin-messages-queue's People

Contributors

jespino avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

mattermost-plugin-messages-queue's Issues

Install tutorial

How to install this via plugins upload.
It seems like there need to run some npm or anything

Build breaks on linting

Hi,

Thanks a lot for creating the plugin, super useful. I did attempt to build it with the Makefile and the output was looking good until it broke on the lint run.

cd webapp && npm run lint

> [email protected] lint /home/ubuntu/plugins/mattermost-plugin-messages-queue-master/webapp
> eslint --ignore-pattern node_modules --ignore-pattern dist --ext .js --ext .jsx --ext tsx --ext ts . --quiet --cache

Warning: React version not specified in eslint-plugin-react settings. See https://github.com/yannickcr/eslint-plugin-react#configuration .

/home/ubuntu/plugins/mattermost-plugin-messages-queue-master/webapp/src/client.ts
   5:1  error  Expected indentation of 4 spaces but found 6                     @typescript-eslint/indent
   5:7  error  Missing accessibility modifier on method definition constructor  @typescript-eslint/explicit-member-accessibility
   6:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
   7:1  error  Expected indentation of 4 spaces but found 6                     @typescript-eslint/indent
   8:1  error  Trailing spaces not allowed                                      no-trailing-spaces
   9:1  error  Expected indentation of 4 spaces but found 6                     @typescript-eslint/indent
   9:7  error  Missing accessibility modifier on class property getConnected    @typescript-eslint/explicit-member-accessibility
  10:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  11:1  error  Expected indentation of 4 spaces but found 6                     @typescript-eslint/indent
  13:1  error  Expected indentation of 4 spaces but found 6                     @typescript-eslint/indent
  13:7  error  Missing accessibility modifier on class property doPost          @typescript-eslint/explicit-member-accessibility
  14:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  15:1  error  Trailing spaces not allowed                                      no-trailing-spaces
  16:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  17:1  error  Expected indentation of 12 spaces but found 14                   @typescript-eslint/indent
  18:1  error  Expected indentation of 12 spaces but found 14                   @typescript-eslint/indent
  19:1  error  Expected indentation of 12 spaces but found 14                   @typescript-eslint/indent
  20:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  21:1  error  Trailing spaces not allowed                                      no-trailing-spaces
  22:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  23:1  error  Trailing spaces not allowed                                      no-trailing-spaces
  24:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  25:1  error  Expected indentation of 12 spaces but found 14                   @typescript-eslint/indent
  26:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  27:1  error  Trailing spaces not allowed                                      no-trailing-spaces
  28:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  29:1  error  Trailing spaces not allowed                                      no-trailing-spaces
  30:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  31:1  error  Expected indentation of 12 spaces but found 14                   @typescript-eslint/indent
  32:1  error  Expected indentation of 12 spaces but found 14                   @typescript-eslint/indent
  33:1  error  Expected indentation of 12 spaces but found 14                   @typescript-eslint/indent
  34:1  error  Expected indentation of 8 spaces but found 10                    @typescript-eslint/indent
  35:1  error  Expected indentation of 4 spaces but found 6                     @typescript-eslint/indent

/home/ubuntu/plugins/mattermost-plugin-messages-queue-master/webapp/src/index.ts
  17:29  error  Empty block statement  no-empty

โœ– 34 problems (34 errors, 0 warnings)
  30 errors and 0 warnings potentially fixable with the `--fix` option.

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] lint: `eslint --ignore-pattern node_modules --ignore-pattern dist --ext .js --ext .jsx --ext tsx --ext ts . --quiet --cache`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] lint script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/ubuntu/.npm/_logs/2021-10-29T19_59_30_139Z-debug.log
make: *** [Makefile:51: check-style] Error 1

I installed golangci-lint using the provided amd64 deb and eslint via apt, but it didn't make a difference. I would love to contribute any README docs on the build process if the plugin can build successfully. This is on Ubuntu 20.04.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.