removed redundant code

This commit is contained in:
2025-08-23 13:09:56 +02:00
parent be23ea461e
commit bf3a26a4fd

View File

@@ -537,40 +537,6 @@ while true; do
[ "$key" = "tab" ] && set -- "--search-artist" [ "$key" = "tab" ] && set -- "--search-artist"
[ "$lns" -eq 2 ] && [ ! "$key" ] && [ "$mid" ] && set -- "--releasegroup" "$mid" [ "$lns" -eq 2 ] && [ ! "$key" ] && [ "$mid" ] && set -- "--releasegroup" "$mid"
;; ;;
"--artists")
sel=$(
printf "" |
$FZF \
--no-clear \
--ansi \
--reverse \
--no-sort \
--disabled \
--cycle \
--delimiter="\t" \
--prompt="$SEARCH_PROMPT" \
--info="inline-right" \
--info-command="echo \"Search music artist\"" \
--accept-nth="{2}" \
--with-nth="{1}" \
--preview-window="right,25%,border-left,wrap,<30(hidden)" \
--preview="$0 --internal-preview-artist {2}" \
--expect="ctrl-c,ctrl-q,tab" \
--bind="load:transform:[ \"\$FZF_TOTAL_COUNT\" -gt 0 ] && echo \"rebind:ctrl-l\" || echo \"unbind:ctrl-l\"" \
--bind="ctrl-l:accept" \
--bind="ctrl-d:half-page-down,ctrl-u:half-page-up" \
--bind="down:preview-half-page-down,up:preview-half-page-up" \
--bind="alt-b:execute-silent:xdg-open 'https://musicbrainz.org/artist/{r2}' &" \
--bind="change:execute-silent($0 --internal-search artist \$FZF_QUERY &)+reload($0 --internal-reload)" || true
)
lns=$(echo "$sel" | wc -l)
key=$(echo "$sel" | head -1 | tail -1)
mid=$(echo "$sel" | head -2 | tail -1)
[ "$key" = "ctrl-c" ] && tput rmcup && exit 0
[ "$key" = "ctrl-q" ] && tput rmcup && exit 0
[ "$key" = "tab" ] && set -- "--search-releasegroup"
[ "$lns" -eq 2 ] && [ ! "$key" ] && [ "$mid" ] && set -- "--artist" "$mid"
;;
*) *)
sel=$( sel=$(
printf "" | printf "" |