Coder Social home page Coder Social logo

tadej / hinko Goto Github PK

View Code? Open in Web Editor NEW
5.0 2.0 1.0 6.38 MB

Slack bot written in Go that supports data storage, concurrent ASCII animations, group formation, random team picking (e.g. for foosball, code reviews).

License: MIT License

Go 99.78% Shell 0.22%

hinko's Introduction

Build Status

Hinko (slack bot)

About the project

My weekend project aimed to help me learn Go while having some fun. Makes good use of goroutines, channels, function signatures, slices, etc. It has its own database (leveldb), downloads images from the web and converts them to ASCII, plays/streams concurrent ASCII animations into posts (by posting and editing a message in the channel repeatedly), etc. I spent some time cleaning up the code (mostly to learn) but I'm sure it can be improved a lot. Enjoy!

screenshot

Slack bot for random team picking and ASCII fun

A Slack bot written in go with its own database that can help you pick random teams (e.g. for foosball, code reviews, etc.).

It features a number of ASCII art and animation experiments, along with the ability to create custom named groups and put/get values.

The bot uses reactions to confirm commands (or say they don't work) to not spam the channel.

screenshot

Try the following commands:

put key value
get key
group groupname list
group groupname create @user1 @user2 @user3 ...
group groupname add @user1 @user2 @user3 ...
group groupname remove @user1 @user2 @user3 ...
score add team1:team2 score1:score2
score get team2:team1
score reset team2:team1
randompairs @user1 @user2 @user3 ...
randompairs group
randomteams teamsize @user1 @user2 @user3 ...
randomteams teamsize group
ascii https://imageurl
shark
animate

screenshot

How do I get a Slack bot running?

Check out this great tutorial: https://rsmitty.github.io/Slack-Bot/

hinko's People

Contributors

davidkuridza avatar tadej avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

davidkuridza

hinko's Issues

Function score add should return current score

Function score add should return current score
Example:
@Hinko score add cobras:hawks 1:2 // should return

COBRAS are currently ahead of HAWKS: 18:6.

Here are the latest match results:
2:1 on Tue, 19 Feb 2019 16:07:55 CET
2:0 on Mon, 18 Feb 2019 16:07:17 CET
2:0 on Thu, 07 Feb 2019 14:12:18 CET
2:0 on Wed, 06 Feb 2019 15:11:29 CET

If score between two teams is equal

If score between 2 teams is equal they are both shown as second (second place medals) but in RL they are both first. You split the first place not the second.

Score set functionality

It would be nice to have score set functionality for example for 2 players who already played 100 games before the age of hinko.

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.