Coder Social home page Coder Social logo

twitter-imagebot's Introduction

twitter-imagebot

A simple-to-use twitter-imagebot written in Ruby

Usage

ruby bot.rb

Tip: If you host this bot on a server be sure to run it in a screen/tmux session, so it won't stop when you disconnect

Setup

Requirements

  • Ruby: Simple as that, there should be a package for *nix-systems simply called ruby, on Windows just install RubyInstaller

Preparations

  • Run bundle install to install all other requirements to get the bot running without problems

Configuration

First of all, rename both config.example.yml and images.example.yml to config.yml and images.yml

config.yml

  • username: Filling this in will show you as a hoster of this bots instance on startup
  • sleep_time: Time (in minutes) the bot will pause between posting images (default: 15)
  • image_directory: Directory the images for this bot are placed in (default: img/)
Twitter
  • Go to Twitter Apps and create a new application
  • Generate your consumer/access token keys/secrets for Read and Write access
  • Add your consumer/access token keys/secrets to the twitter block inside config.yml

images.yml

Every block for one image looks like this:

- name: IMAGE_NAME_HERE
  location: IMAGE_LOCATION_HERE
  source: IMAGE_SOURCE HERE
  • name: The name of the image displayed in the tweet (use character names or the title specified by the artist)
  • location: The filename/location of one image, you can just use image names or include directories in between (examples: image.jpg, dir/image.jpg)
  • source: The link to the original image, as the artist published it (no, (any)chan, (any)booru are no sources)

License & Notice to Hosters

twitter-imagebot is licensed under the MIT License

Also, regarding the licensing, I'd like you (if you set up a bot with this software) to put at least the link to my Github profile or to this repository in it's profile, so people know who made the software behind this.

twitter-imagebot's People

Contributors

pixeldesu avatar

Watchers

 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.