From d358d7229458fe97ea79f341d478d5162c913bc7 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Tue, 8 Jun 2021 19:03:47 -0300 Subject: scripts/pastebin.sh: Tweak to remove color dependency and update publishing method --- scripts/pastebin.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'scripts') diff --git a/scripts/pastebin.sh b/scripts/pastebin.sh index e12096bd..d306f878 100755 --- a/scripts/pastebin.sh +++ b/scripts/pastebin.sh @@ -2,8 +2,9 @@ set -eu usage() { - red "Missing argument <${1}>.\n" cat <. + Usage: pastebin.sh [-|FILE] @@ -51,7 +52,7 @@ fi cd ~/dev/libre/website > /dev/null [ -f "$OUT" ] && { - red "Pastebin named $OUT already exists." + echo "Pastebin named $OUT already exists." exit 1 } @@ -78,6 +79,6 @@ EOF git reset . git add "$OUT" git commit -m "$0: Auto-add $OUT" -"$(nix-build -A publishScript)/bin/publish.sh" +make publish open "https://euandre.org/pastebin/$(echo "$PASTE_DATE" | tr '-' '/')/$SLUG_TITLE.html" cd - > /dev/null -- cgit v1.3