#!/usr/bin/env bash # This script takes the output of a text-based news bot at: # # bot@happynetbox.com (via goose@happynetbox.com) # # makes the links clickable (using textnet's built in renderer) and # reformats the output using sed. # the autogenerated filename is a timestamp. This allows for multiple runs # during the day without overwriting the previous check if necessary. timestamp=$(date +%Y.%m.%d-%H.%M) textnet -r bot@happynetbox.com > $timestamp.htm && sed -i 's| - |
|g; s|(()|)

|g; s|news:|news:
|' $timestamp.htm && firefox $timestamp.htm # To delete the file after the browser closes, uncomment below: # rm "$timestamp.htm"