Browse Source

Booxdown is now a bash script, and does light error checking

Samuel W. Flint 1 year ago
parent
commit
d106b0f7af
1 changed files with 8 additions and 1 deletions
  1. 8 1
      download-page-to-md

+ 8 - 1
download-page-to-md

@@ -1,4 +1,11 @@
-#!/bin/sh
+#!/usr/bin/env bash
+set -euo pipefail
+IFS=$'\n\t'
+
+if [ $# -lt 2 ] ; then
+    echo "$(basename $0) URL MARKDOWN-FILE" >&2
+    exit 1
+fi
 
 URL=$1
 MDFILE=$2