From cd508eb3e5f9cd3986b93df3b4497d564ebb732b Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sun, 31 Aug 2014 03:01:05 -0400 Subject: [PATCH] Fix bins --- bin/html2pdf | 5 +---- bin/prowl | 25 ------------------------- 2 files changed, 1 insertion(+), 29 deletions(-) delete mode 100755 bin/prowl diff --git a/bin/html2pdf b/bin/html2pdf index 60e29738..37660525 100755 --- a/bin/html2pdf +++ b/bin/html2pdf @@ -5,10 +5,7 @@ # # Note: MAC ONLY! -if ! is_mac; then - echo "Mac-only script!" - exit -elif ! command_exists wkhtmltopdf; then +if ! command -v "wkhtmltopdf" &> /dev/null; then # wkhtmltopdf > 0.9.9 has a habit of hanging after it completes, so we # install 0.9.9 explicitly instead. brew install https://raw.github.com/mxcl/homebrew/6e2d550cf4961129a790bfb0973f8e88704f439d/Library/Formula/wkhtmltopdf.rb diff --git a/bin/prowl b/bin/prowl deleted file mode 100755 index 6913a637..00000000 --- a/bin/prowl +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env ruby - -# A quick script for sending myself prowl notifications - -require 'prowl' - -APIKEY_FILE = File.expand_path("~/.prowl-apikey") - -if ARGV.length != 3 - p "Usage: prowl [appname] [title] [message]" - exit -end - -if not File.exists? APIKEY_FILE - p "#{APIKEY_FILE} does not exist. Create it!" - exit -end - -api_key = File.read(APIKEY_FILE).strip -Prowl.add( - :apikey => api_key, - :application => ARGV[0], - :event => ARGV[1], - :description => ARGV[2] -)