Skip to content
Seb Pearce's New Age Bullshit Generator (https://github.com/sebpearce/bullshit), adapted for the Twitterverse
JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
LICENSE
README.md
main.js
package.json

README.md

New Age BS Bot

Welcome to the New Age Bullshit bot!

This is a quick project built upon Seb Pearce's excellent New Age Bullshit Generator that takes the incredibly humorous output of the NABG and presents it to the Internet in tweet form.

This is the very same Openshift package that I use to host @nabgbot, which posts at a 15 minute interval. The code has also been configured to redirect to the bot's twitter profile should a user make an HTTP request to the application (e.g. at nabgbot-ctis.rhcloud.com).

After filling in the configuration, you should be able to simply import the repo into an Openshift gear and be ready to go. You may also wish to adjust the interval at which tweets are posted (the default is one post every 15 minutes).

Note: If you don't want to host your bot on Openshift and would prefer to run it as a script with a cron job or something, have a look at this repository at this commit.

##Quickstart

Assuming that you already have some amount of familiarity with Openshift, tnitial setup is quite easy. Simply clone this repository to your local machine, grab your Twitter API keys, and fill out the bot configuration. Once finished, create your NodeJS application and push your newly configured bot to your gear.

Note: You'll probably want to upgrade your Openshift account plan to the Bronze tier in order to avoid application idling, which effectively "sleeps" your app until it recieves HTTP requests (thus disrupting posts). Check out this explanation for pricing deets.

##Configuration

All configuration is located in the CONFIG object:

  • CONFIG.TWITTER_API_KEYS: The API keys that your bot will use to connect to Twitter. Get these from https://apps.twitter.com

  • CONFIG.IP: The external IP address of the Openshift gear. This is automatically retrieved, or if you're running a local instance will default to 127.0.0.1

  • CONFIG.PORT: The port on which the gear's HTTP server is accessible. This is also retrieved automatically, however, it will default to port 8082 on your local machine.

  • CONFIG.TWITTER_URL: The URL of your bot's Twitter profile. This is used to serve a redirect should the application be visited from its external URL.

  • CONFIG.POST_INTERVAL: The interval at which posts are made, in milliseconds. The default is 900000ms, which is 15 minutes. Be sure to keep Twitter's API rate limits in mind when adjusting this.

Enjoy!

See it in action: @nabgbot

You can’t perform that action at this time.