Giter Club home page Giter Club logo

slacknimate's Introduction

slacknimate

text animation for Slack messages ๐Ÿ‘ฏ

slacknimate1

slacknimate2

Installation

Download a binary from the Releases Page and put it somewhere on your $PATH.

Mac OS X Homebrew users, you can also just brew install slacknimate.

Authentication

Generate your Slack user token on this page.

You'll need to either pass it to the program via the --api-token flag or store it as SLACK_TOKEN environment variable.

If you want the message to come from a bot name/icon instead, see "Bots" section at the bottom of this README.

Usage

NAME:
   slacknimate - text animation for Slack messages

USAGE:
   slacknimate [options]

VERSION:
   1.0.0

COMMANDS:
   help, h	Shows a list of commands or help for one command

GLOBAL OPTIONS:
   --api-token, -a      API token* [$SLACK_TOKEN]
   --delay, -d "1"      minimum delay between frames
   --channel, -c        channel/destination* [$SLACK_CHANNEL]
   --loop, -l           loop content upon reaching end
   --preview            preview on terminal instead of posting
   --help, -h           show help
   --version, -v        print the version

Simple animation loops

$ slacknimate -c "#general" --loop < examples/emoji.txt

slacknimate1

Realtime process monitoring

Why spam a chatroom with periodic monitoring messages when you can have realtime status updates so that a message is never out of date?

See for example this example:

$ ./examples/process.sh 5 | slacknimate -c "#devops"
2016/02/23 19:03:14 initial frame G07AJU0SH/1456272194.000086: Processing items: 0/5
2016/02/23 19:03:15 updated frame G07AJU0SH/1456272194.000086: Processing items: 1/5
2016/02/23 19:03:16 updated frame G07AJU0SH/1456272194.000086: Processing items: 2/5
2016/02/23 19:03:17 updated frame G07AJU0SH/1456272194.000086: Processing items: 3/5
2016/02/23 19:03:18 updated frame G07AJU0SH/1456272194.000086: Processing items: 4/5
2016/02/23 19:03:19 updated frame G07AJU0SH/1456272194.000086: Processing items: 5/5

Done!

slacknimate2

Preview in terminal

If you aren't certain about your source, you can preview what the animation would look like in the terminal via the --preview flag.

$ slacknimate --preview --loop -d 0.25 < examples/sample.txt

slacknimate3

Bots

In order for Slack message editing to work, the message must be posted as_user: true, which will show as coming from whomever owns the token. This is due to how the security model for Slack message editing works.

For bots, you must create a new bot in the team settings and substitute in the auth token for that bot.

slacknimate's People

Contributors

mroth avatar llkats avatar micw avatar p-v avatar

Watchers

 avatar James Cloos avatar  avatar

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.