From 553bdff07d994668eb8f53c5f36cd90159c71c96 Mon Sep 17 00:00:00 2001 From: Alexander Bocken Date: Sun, 3 Jan 2021 19:24:58 +0100 Subject: [PATCH] fixed typo, correct error code on exit --- installer | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/installer b/installer index 0345ae3..4034bc6 100755 --- a/installer +++ b/installer @@ -1,5 +1,5 @@ #!/bin/sh -DESTDIR="/usr/local/bin" +DESTDIR="$HOME/.local/bin" XDG_VIDEOS_DIR=$HOME/vids #TODO ADJUST FOR PERSONAL USE HERE! DLARCHIVE="${XDG_VIDEOS_DIR:-$HOME/Videos}/.downloaded" DLLOC="${XDG_VIDEOS_DIR:-$HOME/Videos}" @@ -8,10 +8,10 @@ BLACKLIST="${XDG_VIDEOS_DIR:-$HOME/Videos}/.blacklist" install(){ mkdir -p "$DLLOC" "$(dirname "$CHANNELSFILE")" "$(dirname "$DLARCHIVE")" "$(dirname "$BLACKLIST")" "$DESTDIR" - cp ripper "$DESTDIR/ripper" - [ ! -f "$CHANNELSFILE" ] && printf '#Add channels to add in this file\n#Format: https://www.youtube.com/channel/' > "$CHANNELSFILE" - [ ! -f "$BLACKLIST" ] && printf '#Add video URIs here (not just the IDs)' > "$BLACKLIST" - [ ! -f "$DLARCHIVE" ] && printf '#These videos will not be attempted to download again' > "$DLARCHIVE" + cp -f ripper "$DESTDIR/ripper" + [ -f "$CHANNELSFILE" ] || printf '#Add channels in this file\n#Format: https://www.youtube.com/channel/' > "$CHANNELSFILE" + [ -f "$BLACKLIST" ] || printf '#Add video URIs here (not just the IDs)' > "$BLACKLIST" + [ -f "$DLARCHIVE" ] || printf '#These videos will not be attempted to download again' > "$DLARCHIVE" } uninstall(){