diff --git a/.local/bin/yt-browser b/.local/bin/ybrowser similarity index 96% rename from .local/bin/yt-browser rename to .local/bin/ybrowser index e7cf932a..43538369 100644 --- a/.local/bin/yt-browser +++ b/.local/bin/ybrowser @@ -8,6 +8,11 @@ CUSTOM_LIST_DIR="$DATA_DIR/custom_lists" mkdir -p "$DATA_DIR" "$DOWNLOAD_DIR" "$CUSTOM_LIST_DIR" +[ "$(find "$DATA_DIR" -maxdepth 1 -type f -name "*.tsv" 2>/dev/null)" ] || { + notify-send "You need to run "channelrefresh" script first." + exit 1 +} + DMENU() { dmenu -i -l $1 -p "$2" } @@ -64,7 +69,7 @@ custom_list_menu() { [ -z "$list" ] && return case "$list" in *CREATE*) - new_list=$(DMENU 0 "Enter the name of the new list") + new_list=$(echo "" | DMENU 0 "Enter the name of the new list") [ -n "$new_list" ] && touch "$CUSTOM_LIST_DIR/$new_list" ;; *DELETE*)