Skip to content

A Hubot script which splits up messages longer than a predefined length

License

Notifications You must be signed in to change notification settings

chen-ye/hubot-chunkify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hubot-chunkify

npm version

This script relies on a new Hubot v2.17.0 feature known as 'response middleware'. It WILL NOT work on older versions of Hubot.

A Hubot script for handling long messages by chunking them up into shorter messages. Useful for gracefully handling adapters that have a maximum message length. Test it out on hubot help.

Installation via NPM

  1. Install the hubot-chunkify module as a Hubot dependency by running:

    npm install --save hubot-chunkify
    
  2. Enable the module by adding the hubot-chunkify entry to your external-scripts.json file:

    [
        "hubot-chunkify"
    ]
  3. Run your bot and see below for available config / commands

Configuration

Variable Default Description
HUBOT_CHUNKIFY_MAX 320 Any message sent by Hubot that is longer than HUBOT_CHUNKIFY_MAX string characters will be replaced by a series of messages split by newline and HUBOT_CHUNKIFY_MAX.

About

A Hubot script which splits up messages longer than a predefined length

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published