Skip to content

Instantly share code, notes, and snippets.

@StevenBlack

StevenBlack/gist:4459239

Last active Dec 10, 2015
Embed
What would you like to do?
Bash script for the #YGK twitter hashtag. Uses the 't' command line client (a Ruby gem). This script uses Gist #4297661 to filter #ygk hashtag spam. https://gist.github.com/4297661
#!/bin/bash
# First install 't', the Twitter command line client: https://github.com/sferik/t#readme
# This is a Ruby gem and if you are on Mac OS X or any flavour of *nix you're probably got Ruby.
# Next ensure you have 'curl' installed (on Mac OS X you probably do)
# Given these two prerequisites then...
# Step 1: Grab the latest #ygk fluff filter from Gist #4297661 in raw form
EXCL="`curl https://gist.github.com/raw/4297661`"
# Default to 50 tweets but you can pass-in some other number
Q=${1:-50}
# Step 2: Fetch the last 100 #ygk tweets, cleansed of fluff
t search all "$EXCL" -l -n ${Q}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment