Skip to content

Instantly share code, notes, and snippets.

@sternenseemann
Last active December 16, 2015 23:59
Show Gist options
  • Save sternenseemann/5517807 to your computer and use it in GitHub Desktop.
Save sternenseemann/5517807 to your computer and use it in GitHub Desktop.
adnprinter – Print posts of a adn-hashtag
#!/bin/bash
# Depencies: lp & wry
search='#adnprinter' # hashtag/search
count=7 # How many post should be printed?
cd /adnprinter #change that to cd /path/to/adnprinter
posts=$(wry search $search -c $count)
if test "$posts" != "$(cat ./ref.txt)"
then echo "$posts" > ./ref.txt
lp ./ref.txt
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment